many many updates (check commit detail)

- updated dependencies
  - bumped react version 17 -> 18
- changed navbar button tag from `a` to `button`
- added locale info to url (made sure same url = same content)
- fixed 0 gettingconsidered as "unknown length" for
  word count in `PostCard`
- moved functions from `Page.tsx` to `helper.ts`
- added "translation not available" page
This commit is contained in:
Kim, Jimin 2022-04-17 21:49:54 +09:00
parent 56bf555bd7
commit d1a33ccf1e
17 changed files with 2569 additions and 2383 deletions

View file

@ -78,7 +78,7 @@ const PostCard = (props: Props) => {
return (
<StyledPostCard>
<PostCardContainer to={process.env.PUBLIC_URL + postData.url}>
<PostCardContainer to={postData.url}>
<StyledTitle>
{postData.title || "No title"}
{/* show "(series)" for urls that matches regex "/series/<series-title>" */}
@ -107,7 +107,7 @@ const PostCard = (props: Props) => {
&nbsp;&nbsp;&nbsp;&nbsp;
<FontAwesomeIcon icon={faBook} />
&nbsp;&nbsp;&nbsp;
{postData.wordCount
{typeof postData.wordCount === "number"
? postData.wordCount + " words"
: "unknown length"}
</StyledMetaContainer>