Skip to content

Commit ef90a62

Browse files
authored
Un-crunch changelog pagination UI on mobile screens (#28705)
1 parent 1193e9b commit ef90a62

File tree

1 file changed

+10
-2
lines changed

1 file changed

+10
-2
lines changed

src/components/changelog/Pagination.astro

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ const nextUrl = currentPage < lastPage ? pageUrl(currentPage + 1) : null;
5252

5353
{
5454
lastPage > 1 && (
55-
<nav class="pagination mt-8 flex items-center justify-between" aria-label="Pagination">
55+
<nav class="pagination mt-8 flex flex-wrap items-center justify-between gap-y-2" aria-label="Pagination">
5656
{prevUrl ? (
5757
<a href={prevUrl} class="pagination-btn no-underline">
5858
← Prev
@@ -61,7 +61,7 @@ const nextUrl = currentPage < lastPage ? pageUrl(currentPage + 1) : null;
6161
<span class="pagination-btn disabled">← Prev</span>
6262
)}
6363

64-
<div class="flex items-center gap-1">
64+
<div class="pagination-pages flex items-center gap-1">
6565
{items.map((item) =>
6666
item === null ? (
6767
<span class="flex h-9 items-center justify-center px-2 text-sm text-sl-color-gray-3">
@@ -128,4 +128,12 @@ const nextUrl = currentPage < lastPage ? pageUrl(currentPage + 1) : null;
128128
.pagination-btn.disabled {
129129
opacity: 0.35;
130130
}
131+
132+
@media (max-width: 640px) {
133+
.pagination-pages {
134+
order: -1;
135+
width: 100%;
136+
justify-content: center;
137+
}
138+
}
131139
</style>

0 commit comments

Comments
 (0)