theme-game 微调

This commit is contained in:
tangly1024.com
2024-03-22 17:08:40 +08:00
parent 8b407f0ec4
commit dedbb0f811
10 changed files with 188 additions and 82 deletions

View File

@@ -0,0 +1,29 @@
import { useGlobal } from '@/lib/global'
/**
* 文章列表上方嵌入
* @param {*} props
* @returns
*/
export default function BlogPostBar(props) {
const { tag, category } = props
const { locale } = useGlobal()
if (tag) {
return (
<div className='flex items-center text-xl mt-4 px-2'>
<i className='mr-2 fas fa-tag' />
{locale.COMMON.TAGS}:{tag}
</div>
)
} else if (category) {
return (
<div className='flex items-center text-xl mt-4 px-2'>
<i className='mr-2 fas fa-th' />
{locale.COMMON.CATEGORY}:{category}
</div>
)
} else {
return <></>
}
}