From e552de269bde0b506007dbd40868d521c5679687 Mon Sep 17 00:00:00 2001 From: hippoz <10706925-hippoz@users.noreply.gitlab.com> Date: Fri, 22 Apr 2022 23:01:44 +0300 Subject: [PATCH] frontend: improve readability and css --- frontend/public/global.css | 16 +++++++++-- .../components/pages/main/ChannelView.svelte | 6 ++--- .../src/components/pages/main/Main.svelte | 1 + .../src/components/pages/main/Messages.svelte | 27 +++++++++++++++---- 4 files changed, 40 insertions(+), 10 deletions(-) diff --git a/frontend/public/global.css b/frontend/public/global.css index 69465d1..6b65d68 100644 --- a/frontend/public/global.css +++ b/frontend/public/global.css @@ -7,16 +7,27 @@ src: url('assets/woff2/iosevka-aile-regular.woff2') format('woff2'); } +@font-face { + font-family: 'Iosevka Aile Web'; + font-display: swap; + font-weight: 700; + font-stretch: normal; + font-style: normal; + src: url('assets/woff2/iosevka-aile-bold.woff2') format('woff2'); +} + :root { --background-color-1: hsl(180, 11%, 7%); --background-color-2: hsl(180, 11%, 12%); - --foreground-color-1: hsl(0, 0%, 100%); - --foreground-color-2: hsl(0, 0%, 60%); + --foreground-color-1: rgb(253, 254, 255); + --foreground-color-2: rgb(218, 219, 220); + --foreground-color-3: rgb(153, 154, 155); --space-unit: 1em; --space-xxs: calc(0.25 * var(--space-unit)); --space-xs: calc(0.5 * var(--space-unit)); --space-sm: calc(0.75 * var(--space-unit)); + --space-norm: var(--space-unit); --space-md: calc(1.25 * var(--space-unit)); --space-lg: calc(2 * var(--space-unit)); --space-xl: calc(3.25 * var(--space-unit)); @@ -26,6 +37,7 @@ --radius-xxs: calc(0.25 * var(--radius-unit)); --radius-xs: calc(0.5 * var(--radius-unit)); --radius-sm: calc(0.75 * var(--radius-unit)); + --radius-norm: var(--radius-unit); --radius-md: calc(1.25 * var(--radius-unit)); --radius-lg: calc(2 * var(--radius-unit)); --radius-xl: calc(3.25 * var(--radius-unit)); diff --git a/frontend/src/components/pages/main/ChannelView.svelte b/frontend/src/components/pages/main/ChannelView.svelte index 29c50db..89f5ed6 100644 --- a/frontend/src/components/pages/main/ChannelView.svelte +++ b/frontend/src/components/pages/main/ChannelView.svelte @@ -47,6 +47,8 @@
{#each $messages as message (message.id)} -
- { message.author_username } - { message.content } +
+ { message.author_username } + { message.content }
{/each}