Skip to content

Commit 5efaa36

Browse files
committed
format
1 parent e091507 commit 5efaa36

File tree

5 files changed

+23
-7
lines changed

5 files changed

+23
-7
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
"postbuild": "next-sitemap --config next-sitemap.config.js",
99
"start": "next start",
1010
"lint": "next lint",
11-
"format":"prettier --write src"
11+
"format": "prettier --write src"
1212
},
1313
"dependencies": {
1414
"gray-matter": "^4.0.3",

src/app/[article_year]/[month]/[aid]/components/client.tsx

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,9 @@ export default function ClientComponent({
3939
const tocRef = useRef<HTMLElement>(null);
4040
const t = useTranslations("pages.article.content");
4141
const locale = useLocale();
42-
const processedContent = processedContents.find((c) => c.lang === locale)?.content;
42+
const processedContent = processedContents.find(
43+
(c) => c.lang === locale,
44+
)?.content;
4345
const toc = tocs.find((t) => t.lang === locale)?.toc || [];
4446
const [sha256Seed, setSha256Seed] = useState<number | null>(null);
4547
const max_show_others = 2;
@@ -175,7 +177,9 @@ export default function ClientComponent({
175177
</article>
176178
<section className="other-articles relative md:sticky">
177179
<h2>{t("words.others")}</h2>
178-
<ul>{randomOtherArticles.map((other) => generateArticleButton(other))}</ul>
180+
<ul>
181+
{randomOtherArticles.map((other) => generateArticleButton(other))}
182+
</ul>
179183
</section>
180184
</div>
181185
);
Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,13 @@
11
"use client";
22
import { useTranslations } from "next-intl";
33

4-
export default function Explains({ year, month }: { year: string; month: string }) {
4+
export default function Explains({
5+
year,
6+
month,
7+
}: {
8+
year: string;
9+
month: string;
10+
}) {
511
const t = useTranslations("pages.article");
612
return (
713
<>
@@ -11,5 +17,7 @@ export default function Explains({ year, month }: { year: string; month: string
1117
<section className="description">
1218
<p>{t("description.msg1")}</p>
1319
<p>{t("description.msg2")}</p>
14-
</section></>)
20+
</section>
21+
</>
22+
);
1523
}

src/app/[article_year]/components/explains.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,5 +11,7 @@ export default function Explains({ year }: { year: string }) {
1111
<section className="description">
1212
<p>{t("description.msg1")}</p>
1313
<p>{t("description.msg2")}</p>
14-
</section></>)
14+
</section>
15+
</>
16+
);
1517
}

src/app/article/components/explains.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,5 +11,7 @@ export default function Explains() {
1111
<section className="description">
1212
<p>{t("description.msg1")}</p>
1313
<p>{t("description.msg2")}</p>
14-
</section></>)
14+
</section>
15+
</>
16+
);
1517
}

0 commit comments

Comments
 (0)