Merge pull request #42 from tangly1024/theme-medium

修复翻页按钮
This commit is contained in:
tangly1024
2022-01-28 11:01:22 +08:00
committed by GitHub
8 changed files with 9 additions and 5 deletions

View File

@@ -46,6 +46,12 @@
**🕸  网址美观、搜索引擎优化**
- 更多特性、欢迎移步[我的博客](https://tangly1024.com/article/notion-next)查看
## 主题样式
|||
|--|--|
| ![Next Theme](/docs/theme-next.png) | ![Hexo Theme](/docs/theme-hexo.png) |
| ![Medium Theme](/docs/theme-medium.png) | ![Fukasawa Theme](/docs/theme-fukasawa.png) |
## 更新日志
请移步 [更新文档](https://docs.tangly1024.com/zh/changelog)查看
@@ -83,9 +89,6 @@ yarn run start # 本地启动NextJS服务
- **评论**: Gitalk, Cusdis, Utterances
- **图标**[fontawesome](https://fontawesome.com/v5.15/icons?d=gallery)
## 页面样式主题
正在开发中..将支持配置文件切换主题
## License
The MIT License.

Binary file not shown.

Before

Width:  |  Height:  |  Size: 352 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 767 KiB

BIN
docs/theme-fukasawa.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 134 KiB

BIN
docs/theme-hexo.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 123 KiB

BIN
docs/theme-medium.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 74 KiB

BIN
docs/theme-next.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 104 KiB

View File

@@ -6,14 +6,15 @@ import { useGlobal } from '@/lib/global'
/**
* 简易翻页插件
* @param page 当前页码
* @param showNext 是否有下一页
* @param totalPage 是否有下一页
* @returns {JSX.Element}
* @constructor
*/
const PaginationSimple = ({ page, showNext }) => {
const PaginationSimple = ({ page, totalPage }) => {
const { locale } = useGlobal()
const router = useRouter()
const currentPage = +page
const showNext = currentPage <= totalPage
return (
<div className='my-10 flex justify-between font-medium text-black dark:text-gray-100 space-x-2'>
<Link