Skip to content

Open source personal finance application

chore(Styles): update

Ilya Komichev0a3292a02734
diff --git a/assets/css/fullpage.css b/assets/css/fullpage.css
new file mode 100644
index 00000000..f59ca34c
--- /dev/null
+++ b/assets/css/fullpage.css
@@ -0,0 +1,19 @@
+/* Min properties to use fullscreen page and scroll inside div */
+html {
+ height: 100%;
+}
+
+#__nuxt,
+#__layout {
+ overflow: hidden;
+ height: 100%;
+}
+
+body {
+ height: 100%;
+ overscroll-behavior-y: none;
+}
+
+:root {
+ --height: 100vh
+}
diff --git a/assets/css/index.css b/assets/css/index.css
new file mode 100644
index 00000000..c7d0dd55
--- /dev/null
+++ b/assets/css/index.css
@@ -0,0 +1,12 @@
+html {
+ /* Fonts */
+ --font-primary: 'Roboto', 'sans-serif';
+ --font-secondary: 'Nunito', 'Roboto', 'sans-serif';
+ --font-number: 'Unica One', 'Roboto Condensed', 'sans-serif';
+}
+
+body {
+ background: rgb(var(--bg-main) / 1);
+ color: rgb(var(--text-primary) / 1);
+ font-family: var(--font-primary);
+}
diff --git a/assets/css/reset.css b/assets/css/reset.css
new file mode 100644
index 00000000..024dc88e
--- /dev/null
+++ b/assets/css/reset.css
@@ -0,0 +1,7 @@
+* {
+ -webkit-tap-highlight-color: transparent
+}
+
+*:focus {
+ outline: 0;
+}
diff --git a/assets/css/tailwind.css b/assets/css/tailwind.css
index 8b07d2a4..a048545a 100644
--- a/assets/css/tailwind.css
+++ b/assets/css/tailwind.css
@@ -2,12 +2,31 @@
@tailwind components;
@tailwind utilities;
-* {
- -webkit-tap-highlight-color: transparent
-}
+@layer components {
+ .flex-center {
+ @apply flex items-center justify-center;
+ }
+
+ .flex-center-col {
+ @apply flex flex-col items-center justify-center;
+ }
+
+ .size-full {
+ @apply w-full h-full;
+ }
+
+ .absolute-center {
+ position: absolute;
+ top: 50%;
+ left: 50%;
+ transform: translate(-50%, -50%);
+ }
-*:focus {
- outline: 0
+ /* overflowScrollY() */
+ .overflow-scroll-y {
+ @apply overflow-hidden overflow-y-auto;
+ -webkit-overflow-scrolling: touch;
+ }
}
html,
@@ -19,6 +38,7 @@ body {
background: #171717;
user-select: none;
}
+
@media (prefers-color-scheme: light) {
body {
background: #fafafa;
@@ -27,25 +47,3 @@ body {
.light body {
background: #fafafa;
}
-
-html,
-body,
-#__nuxt,
-#__layout {
- height: 100%
-}
-
-:root {
- --height: 100vh
-}
-
-.flex-center {
- @apply flex items-center justify-center;
-}
-
-.absolute-center {
- position: absolute;
- left: 50%;
- top: 50%;
- transform: translate(-50%, -50%)
-}
diff --git a/assets/css/themes.css b/assets/css/themes.css
new file mode 100644
index 00000000..05abc79e
--- /dev/null
+++ b/assets/css/themes.css
@@ -0,0 +1,82 @@
+html {
+ --c-blue-1: #3a7dff;
+}
+
+
+html.dark {
+ /* Text */
+ --text-primary: 255 255 255;
+ --text-secondary: 255 255 255;
+
+ /* Bg */
+ --bg-main: 9 14 23;
+
+ /* Foreground */
+ --foreground-primary: 245 245 245;
+ --foreground-secondary: 245 245 245;
+
+ /* --foreground-main: 28 28 28; */
+ --foreground-main: 23 27 32;
+ --foreground-hover: 58 58 60;
+ --foreground-active: 44 44 46;
+ --foreground-second: 23 23 23;
+
+ /* Accent */
+ --accent-default: 56 148 2451;
+ --accent-primary: 255 255 255;
+
+ /* Item */
+ --item-main: 40 44 55;
+ --item-hover: 31 37 47;
+ --item-primary: 190 190 190;
+}
+
+html.dark-gray {
+ /* Text */
+ --text-primary: 255 255 255;
+ --text-secondary: 255 255 255;
+
+ /* Bg */
+ --bg-main: 27 27 28;
+
+ /* Foreground */
+ --foreground-primary: 245 245 245;
+ --foreground-secondary: 245 245 245;
+
+ --foreground-main: 28 28 28;
+ --foreground-hover: 58 58 60;
+ --foreground-active: 44 44 46;
+ --foreground-second: 23 23 23;
+
+ /* Accent */
+ --accent-default: 10 132 255;
+ --accent-primary: 255 255 255;
+}
+
+
+html.light {
+ /* Text */
+ --text-primary: 64 64 64;
+ --text-secondary: 0 0 0;
+
+ /* Bg */
+ --bg-main: 250 250 250;
+
+ /* Foreground */
+ --foreground-primary: 245 245 245;
+ --foreground-secondary: 245 245 245;
+ --foreground-second: 245 245 245;
+
+ --foreground-main: 235 235 240;
+ --foreground-hover: 188 188 192;
+ --foreground-active: 216 216 220;
+
+ /* Accent */
+ --accent-default: 0 122 255;
+ --accent-primary: 255 255 255;
+
+ /* Item */
+ --item-main: 235 235 240;
+ --item-hover: 188 188 192;
+ --item-active: 216 216 220;
+}
diff --git a/tailwind.config.js b/tailwind.config.js
index d15acd0c..2523b1a2 100644
--- a/tailwind.config.js
+++ b/tailwind.config.js
@@ -13,6 +13,26 @@ module.exports = {
theme: {
extend: {
colors: {
+ primary: 'rgb(var(--text-primary) / <alpha-value>)',
+ secondary: 'rgb(var(--text-secondary) / <alpha-value>)',
+ main: 'rgb(var(--bg-main) / <alpha-value>)',
+ accent: {
+ default: 'rgb(var(--accent-default) / <alpha-value>)',
+ primary: 'rgb(var(--accent-primary) / <alpha-value>)',
+ },
+ foreground: {
+ primary: 'rgba(var(--foreground-primary) / <alpha-value>)',
+ main: 'rgb(var(--foreground-main) / <alpha-value>)',
+ second: 'rgba(var(--foreground-second) / <alpha-value>)',
+ hover: 'rgb(var(--foreground-hover) / <alpha-value>)',
+ active: 'rgb(var(--foreground-active) / <alpha-value>)',
+ },
+ item: {
+ main: 'rgba(var(--item-main) / <alpha-value>)',
+ hover: 'rgba(var(--item-hover) / <alpha-value>)',
+ primary: 'rgba(var(--item-primary) / <alpha-value>)',
+ },
+
232323: '#232323',
blue1: '#58a6ff',
blue3: '#3a7dff',