mirror of
https://github.com/valentineus/popov.link.git
synced 2025-07-05 00:50:25 +03:00
Refactor Pagination component and add Next and Prev components
This commit is contained in:
18
src/components/Pagination/Next.astro
Normal file
18
src/components/Pagination/Next.astro
Normal file
@ -0,0 +1,18 @@
|
||||
---
|
||||
type Props = {
|
||||
readonly url: string;
|
||||
};
|
||||
|
||||
const { url } = Astro.props;
|
||||
---
|
||||
|
||||
<style lang="scss">
|
||||
span {
|
||||
float: right;
|
||||
max-width: 40%;
|
||||
}
|
||||
</style>
|
||||
|
||||
<span>
|
||||
<a href={url}>Next ></a>
|
||||
</span>
|
18
src/components/Pagination/Prev.astro
Normal file
18
src/components/Pagination/Prev.astro
Normal file
@ -0,0 +1,18 @@
|
||||
---
|
||||
type Props = {
|
||||
readonly url: string;
|
||||
};
|
||||
|
||||
const { url } = Astro.props;
|
||||
---
|
||||
|
||||
<style lang="scss">
|
||||
span {
|
||||
float: left;
|
||||
max-width: 40%;
|
||||
}
|
||||
</style>
|
||||
|
||||
<span>
|
||||
<a href={url}>< Prev</a>
|
||||
</span>
|
Reference in New Issue
Block a user