Compare commits

..

No commits in common. "32910d2077f8a993448294d056c9ffd9dbbc91c8" and "186d3c7a0a6b4479d936151c38e839c8ead3796a" have entirely different histories.

11 changed files with 24 additions and 40 deletions

View file

@ -65,7 +65,7 @@ useHead({
<style> <style>
html, html,
body { body {
font-family: var(--preferred-font), Arial, Helvetica, sans-serif; font-family: var(--preferred-font);
box-sizing: border-box; box-sizing: border-box;
color: var(--text-color); color: var(--text-color);
background: var(--optional-body-background); background: var(--optional-body-background);

View file

@ -1,6 +1,5 @@
<template> <template>
<NuxtImg v-if="displayAvatar" <NuxtImg v-if="displayAvatar"
id="display-avatar"
:src="displayAvatar" :src="displayAvatar"
:alt="displayName" /> :alt="displayName" />
<Icon v-else <Icon v-else
@ -37,10 +36,4 @@ if (user) {
} }
} }
</script> </script>
<style scoped>
#display-avatar {
border-radius: var(--pfp-radius);
}
</style>

View file

@ -225,6 +225,7 @@ function getDayDifference(date1: Date, date2: Date) {
.message-author-avatar { .message-author-avatar {
width: 100%; width: 100%;
border-radius: 50%;
} }
.left-column { .left-column {

View file

@ -37,5 +37,6 @@ const displayName = props.user.display_name || props.user.username
.user-avatar { .user-avatar {
width: 2.3em; width: 2.3em;
height: 2.3em; height: 2.3em;
border-radius: 50%;
} }
</style> </style>

View file

@ -19,16 +19,16 @@
<div class="left-column-segment" id="left-column-middle"> <div class="left-column-segment" id="left-column-middle">
<NuxtLink v-for="guild of guilds" :href="`/servers/${guild.uuid}`"> <NuxtLink v-for="guild of guilds" :href="`/servers/${guild.uuid}`">
<NuxtImg v-if="guild.icon" <NuxtImg v-if="guild.icon"
class="sidebar-icon guild-icon" class="sidebar-icon"
:alt="guild.name" :alt="guild.name"
:src="guild.icon" /> :src="guild.icon" />
<NuxtImg v-else-if="!blockedCanvas" <NuxtImg v-else-if="!blockedCanvas"
class="sidebar-icon guild-icon" class="sidebar-icon"
:alt="guild.name" :alt="guild.name"
:src="generateDefaultIcon(guild.name, guild.uuid)" /> :src="generateDefaultIcon(guild.name, guild.uuid)" />
<Icon v-else name="lucide:server" <Icon v-else name="lucide:server"
:style="`color: ${generateIrcColor(guild.uuid, 50)}`" :style="`color: ${generateIrcColor(guild.uuid, 50)}`"
class="sidebar-icon guild-icon" class="sidebar-icon"
:alt="guild.name" /> :alt="guild.name" />
</NuxtLink> </NuxtLink>
</div> </div>
@ -259,8 +259,8 @@ function createDropdown() {
display: flex; display: flex;
flex-direction: column; flex-direction: column;
padding-left: var(--sidebar-margin); padding-left: .25em;
padding-right: var(--sidebar-margin); padding-right: .25em;
padding-top: .5em; padding-top: .5em;
background: var(--optional-sidebar-background); background: var(--optional-sidebar-background);
@ -281,7 +281,6 @@ function createDropdown() {
#left-column-middle { #left-column-middle {
overflow-y: scroll; overflow-y: scroll;
flex-grow: 1; flex-grow: 1;
gap: var(--sidebar-icon-gap);
} }
#middle-left-column { #middle-left-column {
@ -295,16 +294,12 @@ function createDropdown() {
} }
#home-button { #home-button {
height: var(--sidebar-icon-width); height: var(--sidebar-width);
}
.guild-icon {
border-radius: var(--guild-icon-radius);
} }
.sidebar-icon { .sidebar-icon {
width: var(--sidebar-icon-width); width: var(--sidebar-width);
height: var(--sidebar-icon-width); height: var(--sidebar-width);
} }
.sidebar-bottom-buttons { .sidebar-bottom-buttons {

View file

@ -22,7 +22,6 @@
--sidebar-width: 2.5em; --sidebar-width: 2.5em;
--standard-radius: .5em; --standard-radius: .5em;
--button-radius: .6em; --button-radius: .6em;
--guild-icon-radius: 20%; --pfp-radius: 100%;
--pfp-radius: 50%; --preferred-font: "Arial, Helvetica, sans-serif";
--preferred-font: Arial;
} }

View file

@ -19,13 +19,9 @@
--accent-color: #b35719; --accent-color: #b35719;
--accent-highlighted-color: #c76a2e; --accent-highlighted-color: #c76a2e;
--sidebar-icon-width: 2.5em; --sidebar-width: 2.5em;
--sidebar-icon-gap: .25em;
--sidebar-margin: .5em;
--standard-radius: .5em; --standard-radius: .5em;
--button-radius: .6em; --button-radius: .6em;
--guild-icon-radius: 15%; --pfp-radius: 100%;
--pfp-radius: 50%; --preferred-font: "Arial, Helvetica, sans-serif";
--preferred-font: Arial;
} }

View file

@ -23,8 +23,8 @@
--sidebar-width: 2.5em; --sidebar-width: 2.5em;
--standard-radius: .5em; --standard-radius: .5em;
--button-radius: .6em; --button-radius: .6em;
--pfp-radius: 50%; --pfp-radius: 100%;
--preferred-font: Arial; --preferred-font: "Arial, Helvetica, sans-serif";
--optional-body-background: ; /* background element for the body */ --optional-body-background: ; /* background element for the body */
--optional-chat-background: ; /* background element for the chat box */ --optional-chat-background: ; /* background element for the chat box */

View file

@ -22,6 +22,6 @@
--sidebar-width: 2.5em; --sidebar-width: 2.5em;
--standard-radius: .5em; --standard-radius: .5em;
--button-radius: .6em; --button-radius: .6em;
--pfp-radius: 50%; --pfp-radius: 100%;
--preferred-font: Arial; --preferred-font: "Arial, Helvetica, sans-serif";
} }

View file

@ -22,8 +22,8 @@
--sidebar-width: 2.5em; --sidebar-width: 2.5em;
--standard-radius: .5em; --standard-radius: .5em;
--button-radius: .6em; --button-radius: .6em;
--pfp-radius: 50%; --pfp-radius: 100%;
--preferred-font: Arial; --preferred-font: "Arial, Helvetica, sans-serif";
/* --optional-body-background: background */ /* --optional-body-background: background */
--optional-body-background: linear-gradient(45deg, #ed222480, #ed222480, #ed222480, #ed222480, #ed222480, #ed222480, #f35b2280, #f9962180, #f5c11e80, #f1eb1b80, #f1eb1b80, #f1eb1b80, #63c72080, #0c9b4980, #21878d80, #3954a580, #61379b80, #93288e80); --optional-body-background: linear-gradient(45deg, #ed222480, #ed222480, #ed222480, #ed222480, #ed222480, #ed222480, #f35b2280, #f9962180, #f5c11e80, #f1eb1b80, #f1eb1b80, #f1eb1b80, #63c72080, #0c9b4980, #21878d80, #3954a580, #61379b80, #93288e80);

View file

@ -27,8 +27,7 @@ export default (name: string, seed: string): string => {
ctx.fillStyle = 'white' ctx.fillStyle = 'white'
ctx.textAlign = 'center' ctx.textAlign = 'center'
ctx.textBaseline = 'middle' ctx.textBaseline = 'middle'
const root = document.documentElement; const preferredFont = document.documentElement.style.getPropertyValue("--preferred-font")
const preferredFont = getComputedStyle(root).getPropertyValue("--preferred-font");
ctx.font = `bold 96px ${preferredFont}, Arial, Helvetica, sans-serif` ctx.font = `bold 96px ${preferredFont}, Arial, Helvetica, sans-serif`
// 136 isn't actually centered, but it *looks* centered // 136 isn't actually centered, but it *looks* centered
ctx.fillText(previewName, 128, 136) ctx.fillText(previewName, 128, 136)