-
Notifications
You must be signed in to change notification settings - Fork 485
Expand file tree
/
Copy paththeme.config.tsx
More file actions
80 lines (77 loc) · 1.88 KB
/
Copy paththeme.config.tsx
File metadata and controls
80 lines (77 loc) · 1.88 KB
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
72
73
74
75
76
77
78
79
80
import { DocsThemeConfig } from "nextra-theme-docs";
import { Footer } from "@/components/Footer";
import { Head } from "@/components/Head";
import { NavbarActions } from "@/components/NavbarActions";
import { PageMain } from "@/components/PageMain";
import { PageTitle } from "@/components/PageTitle";
import { Toc } from "@/components/Toc";
import { Typewriter } from "@/components/Typewriter";
import { InkLogo } from "@/icons/InkLogo";
import { URLS } from "@/utils/urls";
const config: DocsThemeConfig = {
logo: <InkLogo />,
darkMode: false,
// ink #7132f5 (light) / ink-light #9e70ff (dark)
color: {
hue: 259,
saturation: { light: 91, dark: 100 },
lightness: { light: 58, dark: 72 },
},
// background token (see src/globals.css)
backgroundColor: {
light: "255,255,255",
dark: "5,5,6",
},
docsRepositoryBase: URLS.repositoryUrl,
head: Head,
main: PageMain,
components: {
h1: PageTitle,
// Link colours live in globals.css; this only opens external links in a
// new tab.
a(props: { href?: string }) {
const isExternal = props.href?.startsWith("http");
return (
<a
{...props}
{...(isExternal
? { target: "_blank", rel: "noopener noreferrer" }
: {})}
/>
);
},
},
sidebar: {
defaultMenuCollapseLevel: 1,
autoCollapse: true,
toggleButton: false,
},
navbar: {
extraContent: NavbarActions,
},
footer: {
component: Footer,
},
toc: {
backToTop: true,
component: Toc,
},
banner: {
key: "docs-wip",
content: (
<a
className="!text-white hover:!text-white/80"
href="/"
target="_blank"
rel="noopener noreferrer"
>
<Typewriter
text="Mainnet is LIVE!"
prompt
className="ink-banner-typer"
/>
</a>
),
},
};
export default config;