mirror of
https://github.com/d0zingcat/NotionNext.git
synced 2026-05-13 23:16:47 +00:00
feature: 字数统计调整
This commit is contained in:
@@ -92,7 +92,7 @@ export default function ArticleDetail ({ post, blockMap, recommendPosts, prev, n
|
||||
{post.summary}
|
||||
</h2>
|
||||
|
||||
<section className='flex justify-end py-2 pl-1 dark:text-white items-center font-light italic text-sm'>
|
||||
<section className='flex justify-end py-2 pl-1 text-gray-600 dark:text-gray-400 items-center font-light text-sm'>
|
||||
<WordCount/>
|
||||
</section>
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
import { faClock, faFileWord } from '@fortawesome/free-solid-svg-icons'
|
||||
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome'
|
||||
import { useEffect } from 'react'
|
||||
|
||||
/**
|
||||
@@ -10,7 +12,7 @@ export default function WordCount () {
|
||||
})
|
||||
|
||||
return <div id='wordCountWrapper' className='hidden'>
|
||||
本文共<strong id='wordCount'>0</strong>字,阅读需要约<strong id='readTime'>0</strong>分钟
|
||||
<FontAwesomeIcon icon={faFileWord}/> 本文字数 <strong id='wordCount'>0</strong> | <FontAwesomeIcon icon={faClock}/> 阅读时长 ≈ <strong id='readTime'>0</strong> 分钟
|
||||
</div>
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user