refac: styling

This commit is contained in:
Timothy Jaeryang Baek 2024-12-23 00:41:22 -07:00
parent 76c8602324
commit cdc75237b2

View File

@ -39,10 +39,10 @@
{#if message} {#if message}
<div <div
class="flex flex-col justify-between px-5 {showUserProfile class="flex flex-col justify-between px-5 {showUserProfile
? 'mt-3' ? 'pt-1.5 pb-0.5'
: ''} w-full {($settings?.widescreenMode ?? null) : ''} w-full {($settings?.widescreenMode ?? null)
? 'max-w-full' ? 'max-w-full'
: 'max-w-5xl'} mx-auto rounded-lg group" : 'max-w-5xl'} mx-auto group hover:bg-gray-500/5 transition"
> >
<div <div
class=" flex w-full message-{message.id}" class=" flex w-full message-{message.id}"
@ -56,17 +56,27 @@
<ProfileImage <ProfileImage
src={message.user?.profile_image_url ?? src={message.user?.profile_image_url ??
($i18n.language === 'dg-DG' ? `/doge.png` : `${WEBUI_BASE_URL}/static/favicon.png`)} ($i18n.language === 'dg-DG' ? `/doge.png` : `${WEBUI_BASE_URL}/static/favicon.png`)}
className={'size-7'} className={'size-8 translate-y-1 mr-0.5'}
/> />
{:else} {:else}
<div class="w-7 h-7 rounded-full bg-transparent" /> <!-- <div class="w-7 h-7 rounded-full bg-transparent" /> -->
{#if message.created_at}
<span
class=" text-xs self-center invisible group-hover:visible text-gray-500 font-medium first-letter:capitalize"
>
{dayjs(message.created_at / 1000000).format('HH:mm')}
</span>
{/if}
{/if} {/if}
</div> </div>
<div class="flex-auto w-0 pl-1"> <div class="flex-auto w-0 pl-1">
{#if showUserProfile} {#if showUserProfile}
<Name> <Name>
{message?.user?.name} <span class="text-sm">
{message?.user?.name}
</span>
{#if message.created_at} {#if message.created_at}
<span <span