-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathogNode.jsx
More file actions
32 lines (31 loc) · 917 Bytes
/
ogNode.jsx
File metadata and controls
32 lines (31 loc) · 917 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
import formatDate from './utils/formatDate';
import React from 'react'; // do not remove
export default function getOgNode(post) {
return (
<section tw="bg-white h-full w-full relative">
<section tw="flex flex-col p-[64px]">
<h1
style="font-family: Inter, NotoSansSC;"
tw="text-[80px] leading-[1.5] m-0 max-w-[90%]"
>
{post.title}
</h1>
<section
style="font-family: Inter, NotoSansSC;"
tw="flex items-center text-[40px] text-neutral-400 mt-[30px]"
>
<span>{formatDate(post.frontmatter.date, 'YYYY 年 M 月 D 日')}</span>
<span tw="mx-[16px]">·</span>
<span>{post.analytics.cjkCharCount} 字</span>
</section>
</section>
<p
style="font-family: Inter, NotoSansSC;"
tw="absolute bottom-[40px] right-[64px] text-[30px]"
>
<strong>Solitude Scroll</strong>
<span tw="mx-[8px]">/</span>subilan.win
</p>
</section>
);
}