fix(ui): stack package rows on phones and drop pager edge buttons

At 320px the package name shared a row with the registry badge, size and downloads, so it had about 90px and scoped names broke mid-word. Below sm the name now takes the full width with the meta row underneath. The pager's first and last buttons wrapped onto a second line inside the card; the page list already reaches the first and last pages, so the edge buttons are off.
This commit is contained in:
2026-11-23 12:29:40 +00:00
parent c022824d2b
commit 99c885cd88
+4 -2
View File
@@ -47,8 +47,9 @@
:value="`${group.registry}:${group.name}`" :value="`${group.registry}:${group.name}`"
> >
<AccordionTrigger :heading-level="2"> <AccordionTrigger :heading-level="2">
<span class="flex w-full min-w-0 items-center justify-between gap-4"> <!-- Stacked below sm: a side-by-side row leaves the name ~90px at 320px and breaks scoped names mid-word. -->
<span class="min-w-0 text-start"> <span class="flex w-full min-w-0 flex-col items-start gap-2 sm:flex-row sm:items-center sm:justify-between sm:gap-4">
<span class="w-full min-w-0 text-start sm:w-auto">
<span class="block break-words font-semibold">{{ group.name }}</span> <span class="block break-words font-semibold">{{ group.name }}</span>
<span class="block text-sm text-muted-foreground"> <span class="block text-sm text-muted-foreground">
{{ group.versions.length }} version{{ group.versions.length > 1 ? 's' : '' }} {{ group.versions.length }} version{{ group.versions.length > 1 ? 's' : '' }}
@@ -115,6 +116,7 @@
:page="currentPage" :page="currentPage"
:total="allGroupedPackages.length" :total="allGroupedPackages.length"
:page-size="itemsPerPage" :page-size="itemsPerPage"
:show-edges="false"
@update:page="changePage" @update:page="changePage"
/> />
</div> </div>