Skip to content

Commit 12aa7c7

Browse files
committed
some docs
1 parent 1dbf9fe commit 12aa7c7

File tree

2 files changed

+176
-2
lines changed

2 files changed

+176
-2
lines changed

src/app/globals.css

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
@import "tw-animate-css";
33

44
:root {
5+
--code-bg: #f4f4f5; /* light gray */
6+
--code-fg: #111827; /* dark text */
57
/* Base theme variables */
68
--radius: 0.625rem;
79
--background: oklch(1 0 0);
@@ -63,6 +65,8 @@
6365
}
6466

6567
[data-theme='dark'] {
68+
--code-bg: #282c34; /* dark code background */
69+
--code-fg: #f3f4f6;
6670
/* Dark theme base colors */
6771
--background: rgb(26, 26, 26);
6872
--foreground: rgb(238, 238, 238);
@@ -150,6 +154,7 @@ p {
150154
}
151155

152156
code {
157+
background-color: var(--code-bg);
153158
color: var(--sh-identifier);
154159
padding: 0.1em 0.4em; /* Add some padding */
155160
border-radius: 4px; /* Rounded corners */
@@ -158,8 +163,9 @@ code {
158163
}
159164

160165
pre {
161-
background-color: #282c34; /* Dark background for full code block */
162-
color: #ffffff; /* Default text color */
166+
background-color: var(--code-bg);
167+
color: var(--code-fg);
168+
/* color: #ffffff; */
163169
padding: 0.2em 0.25em; /* Add padding inside the block */
164170
border-radius: 8px; /* Smooth rounded edges */
165171
overflow-x: auto; /* Handle horizontal overflow for long lines */

src/app/resources/guides/page.mdx

Lines changed: 168 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,134 @@ import Image from 'next/image';
44
import SharedContent from './SharedContent.mdx'
55
import { withBasePath } from '@/lib/utils';
66

7+
## *next-project-site* file structure
8+
9+
```
10+
├── components.json
11+
├── eslint.config.mjs
12+
├── LICENSE
13+
├── mdx-components.tsx
14+
├── next-env.d.ts
15+
├── next.config.ts
16+
├── package.json
17+
├── postcss.config.mjs
18+
├── public
19+
│ ├── logo.png
20+
│ ├── logoFP.png
21+
│ ├── logoVA.png
22+
│ └── t2m_despair_map.png
23+
├── README.md
24+
├── src
25+
│ ├── app
26+
│ ├── assets
27+
│ ├── components
28+
│ ├── config
29+
│ ├── lib
30+
│ └── utils
31+
└── tsconfig.json
32+
```
33+
34+
## Start adding your content by modifying any of the mdx files in the *app* directory
35+
36+
```
37+
src/app
38+
├── blog
39+
│ ├── [slug]
40+
│ │ └── page.tsx
41+
│ ├── page.tsx
42+
│ └── posts
43+
│ ├── spaces-vs-tabs.mdx
44+
│ ├── static-typing.mdx
45+
│ └── vim.mdx
46+
├── contact
47+
│ └── page.mdx
48+
├── events
49+
│ └── page.mdx
50+
├── favicon.ico
51+
├── globals.css
52+
├── layout.tsx
53+
├── not-found.js
54+
├── page.mdx
55+
├── project
56+
│ ├── about
57+
│ │ └── page.mdx
58+
│ └── team
59+
│ ├── cards
60+
│ │ ├── Alice.mdx
61+
│ │ ├── Laura.mdx
62+
│ │ └── Max.mdx
63+
│ └── page.mdx
64+
├── resources
65+
│ ├── guides
66+
│ │ ├── page.mdx
67+
│ │ └── SharedContent.mdx
68+
│ ├── publications
69+
│ │ └── page.mdx
70+
│ └── tools-data
71+
│ └── page.mdx
72+
└── terms
73+
├── imprint
74+
│ └── page.mdx
75+
└── privacy
76+
└── page.mdx
77+
```
78+
79+
## Create navegation menu
80+
81+
```
82+
// main navigation
83+
export const navigation = [
84+
{
85+
text: 'Project',
86+
isHome: true,
87+
name: 'Next Project Site',
88+
description: "Start your new project site with a clean and modern design.",
89+
items: [
90+
{ text: 'About', link: '/project/about',
91+
description: "Learn more about the project, its goals, and its impact.",
92+
},
93+
{ text: 'Team', link: '/project/team',
94+
description: "Meet the team behind the project, their roles, and contributions.",
95+
},
96+
{ text: 'Partners', link: '/project/partners',
97+
description: "Discover our partners and collaborators who support the project.",
98+
},
99+
{ text: 'Get Involved', link: '/project/get-involved',
100+
description: "Find out how you can contribute to the project and make a difference.",
101+
},
102+
]
103+
},
104+
{
105+
text: 'Resources',
106+
items: [
107+
{ text: 'Publications', link: '/resources/publications',
108+
description: "Access our latest research papers, reports, and articles.",
109+
},
110+
{ text: 'Guides', link: '/resources/guides',
111+
description: "Explore our comprehensive guides on various topics related to the project.",
112+
},
113+
{ text: 'Data & Tools', link: '/resources/tools-data',
114+
description: "Utilize our tools and datasets to support your work and research.",
115+
},
116+
{ text: 'FAQs', link: '/resources/faqs',
117+
description: "Find answers to frequently asked questions about the project and its resources.",
118+
},
119+
]
120+
},
121+
{ text: 'Events', link: '/events' },
122+
{ text: 'News', link: '/blog' },
123+
{ text: 'Contact', link: '/contact' },
124+
];
125+
126+
// footer links
127+
export const navFooter = [
128+
{ text: 'Imprint', link: '/terms/imprint' },
129+
{ text: 'Privacy Policy', link: '/terms/privacy' },
130+
]
131+
```
132+
133+
## Some built-in components
134+
```
7135
<ContentSplitSection
8136
title="Elevate Your Project"
9137
subtitle="Our template helps you reach new heights with innovative solutions"
@@ -17,7 +145,38 @@ import { withBasePath } from '@/lib/utils';
17145
/>}
18146
shadow="true"
19147
/>
148+
```
20149

150+
<ContentSplitSection
151+
title="Elevate Your Project"
152+
subtitle="Our template helps you reach new heights with innovative solutions"
153+
media={
154+
<Image
155+
src={withBasePath("/logo.png")}
156+
alt="A futuristic concept"
157+
width={100}
158+
height={100}
159+
className="rounded-lg shadow-lg"
160+
/>}
161+
shadow="true"
162+
/>
163+
164+
```
165+
export const SharedContentComponent = () => (
166+
<div>
167+
This is the shared content that can be imported into other MDX files.
168+
You can include any MDX or React components <strong>here</strong>.
169+
</div>
170+
);
171+
172+
173+
<ContentSplitSection
174+
title="Elevate Your Project"
175+
subtitle="Our template helps you reach new heights with innovative solutions"
176+
media={<SharedContentComponent />}
177+
mediaPosition="left"
178+
/>
179+
```
21180
export const SharedContentComponent = () => (
22181
<div>
23182
This is the shared content that can be imported into other MDX files.
@@ -33,6 +192,15 @@ export const SharedContentComponent = () => (
33192
mediaPosition="left"
34193
/>
35194

195+
```
196+
<ContentSplitSection
197+
title="Elevate Your Project"
198+
subtitle="Our template helps you reach new heights with innovative solutions"
199+
media={<SharedContent />}
200+
mediaPosition="left"
201+
shadow="true"
202+
/>
203+
```
36204
<ContentSplitSection
37205
title="Elevate Your Project"
38206
subtitle="Our template helps you reach new heights with innovative solutions"

0 commit comments

Comments
 (0)