-
Notifications
You must be signed in to change notification settings - Fork 1
/
theme.config.tsx
71 lines (60 loc) · 2.86 KB
/
theme.config.tsx
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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
import React from "react";
import { DocsThemeConfig, useConfig } from "nextra-theme-docs";
import { useRouter } from "next/router";
import logo from "./src/components/Logo";
const config: DocsThemeConfig = {
project: { link: "https://github.com/kitamuraDev/javasilver-strategy" },
docsRepositoryBase: "https://github.com/kitamuraDev/javasilver-strategy",
logo,
sidebar: {
toggleButton: true,
defaultMenuCollapseLevel: 1,
},
editLink: {
text: "Edit this page on GitHub →",
},
footer: {
text: (
<p style={{ fontSize: "12px" }}>
© {new Date().getFullYear()} JavaSilver Strategy
</p>
),
},
useNextSeoProps: () => {
const { route } = useRouter();
if (route !== "/") {
return { titleTemplate: "%s - JavaSilver Strategy" };
}
return {
titleTemplate:
"JavaSilver Strategy - Java Silver 試験対策サンプルコード集",
};
},
head: () => {
return (
<>
{/* Primary Meta Tags */}
<meta name="title" content="JavaSilver Strategy - Java Silver 試験対策サンプルコード集" />
<meta name="description" content="JavaSilver Strategy は Java言語の認定資格試験である Java Silver の試験対策サンプルコード集です" />
{/* Facebook */}
<meta property="og:type" content="website" />
<meta property="og:url" content="https://javasilver-strategy.vercel.app/" />
<meta property="og:title" content="JavaSilver Strategy - Java Silver 試験対策サンプルコード集" />
<meta property="og:description" content="JavaSilver Strategy は Java言語の認定資格試験である Java Silver の試験対策サンプルコード集です" />
<meta property="og:image" content="https://raw.githubusercontent.com/kitamuraDev/javasilver-strategy/main/public/og.jpg" />
{/* Twitter */}
<meta property="twitter:card" content="summary_large_image" />
<meta property="twitter:url" content="https://javasilver-strategy.vercel.app/" />
<meta property="twitter:title" content="JavaSilver Strategy - Java Silver 試験対策サンプルコード集" />
<meta property="twitter:description" content="JavaSilver Strategy は Java言語の認定資格試験である Java Silver の試験対策サンプルコード集です" />
<meta property="twitter:image" content="https://raw.githubusercontent.com/kitamuraDev/javasilver-strategy/main/public/og.jpg" />
{/* favicon */}
<link rel="icon" href="/favicon.svg" type="image/svg+xml" />
<link rel="icon" href="/favicon.png" type="image/png" />
<link rel="icon" href="/favicon-dark.svg" type="image/svg+xml" media="(prefers-color-scheme: dark)" />
<link rel="icon" href="/favicon-dark.png" type="image/png" media="(prefers-color-scheme: dark)" />
</>
);
},
};
export default config;