mirror of
https://github.com/zoriya/v10.git
synced 2026-08-16 02:45:09 +00:00
chore(site): begin v8 page migration (#177)
This commit is contained in:
@@ -9,49 +9,48 @@ interface Props {
|
||||
const { page } = Astro.props;
|
||||
---
|
||||
|
||||
<nav
|
||||
aria-label="Blog pagination"
|
||||
class="w-full max-w-3xl mx-auto mt-10 text-center text-sm flex items-center justify-center gap-3"
|
||||
>
|
||||
{
|
||||
page.url.prev ? (
|
||||
<a
|
||||
href={page.url.prev}
|
||||
aria-label={`Go to page ${page.currentPage - 1}`}
|
||||
class="grid items-center p-2 border border-light-40 rounded-lg intent:border-dark-40"
|
||||
>
|
||||
<ChevronDown size={12} className="rotate-90" />
|
||||
</a>
|
||||
) : (
|
||||
<button
|
||||
disabled
|
||||
aria-label="Previous page (unavailable)"
|
||||
class="grid items-center p-2 border border-light-40 rounded-lg opacity-40"
|
||||
>
|
||||
<ChevronDown size={12} className="rotate-90" />
|
||||
</button>
|
||||
)
|
||||
}
|
||||
<nav aria-label="Blog pagination" class="w-full max-w-3xl mx-auto mt-10 flex items-center justify-end gap-4">
|
||||
<span>
|
||||
Page {page.currentPage} of {page.lastPage}
|
||||
</span>
|
||||
{
|
||||
page.url.next ? (
|
||||
<a
|
||||
href={page.url.next}
|
||||
aria-label={`Go to page ${page.currentPage + 1}`}
|
||||
class="grid items-center p-2 border border-light-40 rounded-lg intent:border-dark-40"
|
||||
>
|
||||
<ChevronDown size={12} className="-rotate-90" />
|
||||
</a>
|
||||
) : (
|
||||
<button
|
||||
disabled
|
||||
aria-label="Next page (unavailable)"
|
||||
class="grid items-center p-2 border border-light-40 rounded-lg opacity-40"
|
||||
>
|
||||
<ChevronDown size={12} className="-rotate-90" />
|
||||
</button>
|
||||
)
|
||||
}
|
||||
<span class="grid grid-cols-2 gap-1">
|
||||
{
|
||||
page.url.prev ? (
|
||||
<a
|
||||
href={page.url.prev}
|
||||
aria-label={`Go to page ${page.currentPage - 1}`}
|
||||
class="grid items-center p-2 border border-light-40 rounded-lg intent:border-dark-40"
|
||||
>
|
||||
<ChevronDown size={12} className="rotate-90" />
|
||||
</a>
|
||||
) : (
|
||||
<button
|
||||
disabled
|
||||
aria-label="Previous page (unavailable)"
|
||||
class="grid items-center p-2 border border-light-40 rounded-lg opacity-40"
|
||||
>
|
||||
<ChevronDown size={12} className="rotate-90" />
|
||||
</button>
|
||||
)
|
||||
}
|
||||
{
|
||||
page.url.next ? (
|
||||
<a
|
||||
href={page.url.next}
|
||||
aria-label={`Go to page ${page.currentPage + 1}`}
|
||||
class="grid items-center p-2 border border-light-40 rounded-lg intent:border-dark-40"
|
||||
>
|
||||
<ChevronDown size={12} className="-rotate-90" />
|
||||
</a>
|
||||
) : (
|
||||
<button
|
||||
disabled
|
||||
aria-label="Next page (unavailable)"
|
||||
class="grid items-center p-2 border border-light-40 rounded-lg opacity-40"
|
||||
>
|
||||
<ChevronDown size={12} className="-rotate-90" />
|
||||
</button>
|
||||
)
|
||||
}
|
||||
</span>
|
||||
</nav>
|
||||
|
||||
@@ -19,7 +19,7 @@ const { post, authors, asLink } = Astro.props;
|
||||
</time>
|
||||
<div class="mb-3">
|
||||
<h2 class="text-lg font-medium md:text-h4 group-intent:underline mb-1">{post.data.title}</h2>
|
||||
<p class="font-medium md:text-lg text-dark-40 dark:text-light-40">{post.data.description}</p>
|
||||
<p class="font-medium text-dark-40 dark:text-light-40">{post.data.description}</p>
|
||||
</div>
|
||||
{
|
||||
authors.length > 0 && (
|
||||
|
||||
Reference in New Issue
Block a user