Skip to content

Commit 57463a7

Browse files
author
River@devbox
committed
Init
1 parent 435ecbf commit 57463a7

52 files changed

Lines changed: 3852 additions & 1 deletion

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
11
course/build
22
.DS_Store
33
__pycache__
4+
node_modules/
5+
dist
6+
qpycourse

CLAUDE.md

Lines changed: 76 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,76 @@
1+
# CLAUDE.md
2+
3+
This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
4+
5+
## Project Overview
6+
7+
A React + TypeScript single-page application for QPython+ course navigation, built with Vite.
8+
9+
## Tech Stack
10+
11+
- React 18 + TypeScript
12+
- Vite (build tool)
13+
- Tailwind CSS (styling)
14+
- React Router 6 (routing)
15+
- Zustand (state management - available if needed)
16+
- Lucide React (icons)
17+
18+
## Development
19+
20+
```bash
21+
npm install # Install dependencies
22+
npm run dev # Start dev server
23+
npm run build # Build for production (outputs to dist/)
24+
npm run preview # Preview production build
25+
```
26+
27+
## Architecture
28+
29+
```
30+
src/
31+
├── components/ # Reusable UI components
32+
├── context/ # React context (LanguageContext)
33+
├── i18n/ # Translation files (translations.json)
34+
├── lib/ # Utilities (cn helper)
35+
├── pages/ # Route pages (CoursesPage)
36+
├── types/ # TypeScript types
37+
├── App.tsx # Root component with routes
38+
├── main.tsx # Entry point
39+
public/
40+
├── assets/ # Images
41+
├── data/
42+
│ └── courses.json # Course data (edit this to add courses)
43+
```
44+
45+
## Key Files
46+
47+
- `public/data/courses.json` - Course data file. Edit this to add/modify courses.
48+
- `src/i18n/translations.json` - UI translations (zh/en)
49+
- `src/context/LanguageContext.tsx` - Language switching logic
50+
- `src/pages/CoursesPage.tsx` - Main courses listing page
51+
52+
## Adding Courses
53+
54+
Edit `public/data/courses.json`:
55+
56+
```json
57+
{
58+
"courses": [
59+
{
60+
"id": "unique-id",
61+
"title": "Course Title",
62+
"description": "Course description",
63+
"image": "/assets/course-image.png",
64+
"url": "https://example.com",
65+
"tags": ["python", "beginner"],
66+
"difficulty": "beginner"
67+
}
68+
]
69+
}
70+
```
71+
72+
## Notes
73+
74+
- Language auto-detects from browser (`navigator.language`)
75+
- Courses open in new tab via standard `<a>` (no app-specific navigation)
76+
- Images go in `public/assets/`

docs/index.html

Lines changed: 0 additions & 1 deletion
This file was deleted.

index.html

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
<!DOCTYPE html>
2+
<html lang="en">
3+
<head>
4+
<meta charset="UTF-8" />
5+
<link rel="icon" type="image/svg+xml" href="/vite.svg" />
6+
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
7+
<title>QPython+ - Personalized Programming Learning Community</title>
8+
</head>
9+
<body>
10+
<div id="root"></div>
11+
<script type="module" src="/src/main.tsx"></script>
12+
</body>
13+
</html>

0 commit comments

Comments
 (0)