show file sizes (basic version)

This commit is contained in:
2025-09-06 15:49:51 +02:00
parent cef77e86b7
commit 8c0d80d7fb
6 changed files with 71 additions and 37 deletions

View File

@@ -7,6 +7,7 @@ import {
ContextMenuSeparator,
} from '@/components/ui/context-menu';
import type { DirectoryEntry } from '#shared/types';
import byteSize from 'byte-size';
const warrenStore = useWarrenStore();
const copyStore = useCopyStore();
@@ -111,12 +112,10 @@ function onClearCopy() {
class="flex w-full flex-col items-start justify-stretch gap-0 overflow-hidden text-left leading-6"
>
<span class="w-full truncate">{{ entry.name }}</span>
<NuxtTime
v-if="entry.createdAt != null"
:datetime="entry.createdAt * 1000"
<span
class="text-muted-foreground w-full truncate text-sm"
relative
></NuxtTime>
>{{ byteSize(entry.size) }}</span
>
</div>
</button>
</ContextMenuTrigger>