Skip to content

Commit 67c03d8

Browse files
committed
add chinese characters
1 parent 0a24982 commit 67c03d8

File tree

6 files changed

+54
-40
lines changed

6 files changed

+54
-40
lines changed

README.md

Lines changed: 0 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -44,38 +44,3 @@ npm run build
4444
# Preview build
4545
npm run preview
4646
```
47-
48-
## 🚀 Deployment
49-
50-
The website is automatically deployed via GitHub Actions:
51-
52-
1. Push code to `main` branch
53-
2. GitHub Actions automatically builds
54-
3. Deploy to GitHub Pages
55-
56-
## 📝 Content Updates
57-
58-
To update website content, edit `src/pages/index.astro` file, then:
59-
60-
```bash
61-
git add .
62-
git commit -m "Update website content"
63-
git push origin main
64-
```
65-
66-
## 🎨 Features
67-
68-
- ✨ Responsive design
69-
- 🌙 Dark/light theme toggle
70-
- 📱 Mobile optimized
71-
- ⚡ Fast loading
72-
- 🔍 SEO friendly
73-
74-
## 📄 License
75-
76-
MIT License
77-
78-
---
79-
80-
**Contact**: [GitHub](https://github.com/yangchen73)
81-
# Trigger deployment

public/images/宸.svg

Lines changed: 7 additions & 0 deletions
Loading

public/images/杨.svg

Lines changed: 10 additions & 0 deletions
Loading

src/layouts/Layout.astro

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,9 @@ const { title = 'Chen Yang — Academic Homepage', description = 'Research, publ
1818
<link rel="preconnect" href="https://scholar.google.com" />
1919
<link rel="dns-prefetch" href="https://scholar.google.com" />
2020
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=Noto+Sans+SC:wght@400;500;700&display=swap" rel="stylesheet" />
21+
<link href="https://fonts.googleapis.com/css2?family=Noto+Serif+TC:wght@500;600;700&display=swap" rel="stylesheet" />
22+
<!-- LXGW WenKai webfont for Chinese Kaishu style -->
23+
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/lxgw-wenkai-webfont@1.7.0/style.css" />
2124
<meta name="color-scheme" content="light" />
2225
<link rel="preload" href="/cv.pdf" as="document" crossorigin>
2326
<!-- Global CSS is now included via Tailwind -->
@@ -93,9 +96,9 @@ const { title = 'Chen Yang — Academic Homepage', description = 'Research, publ
9396
// Update tab button states
9497
tabButtons.forEach(btn => {
9598
btn.classList.remove('text-blue-600', 'border-blue-600', 'active');
96-
btn.classList.add('text-gray-600');
99+
btn.classList.add('text-gray-600', 'border-transparent');
97100
});
98-
this.classList.remove('text-gray-600');
101+
this.classList.remove('text-gray-600', 'border-transparent');
99102
this.classList.add('text-blue-600', 'border-blue-600', 'active');
100103

101104
// Show corresponding content

src/pages/index.astro

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,15 @@ import Layout from "../layouts/Layout.astro";
99
<div class="text-center md:flex md:items-center md:gap-8 md:text-left">
1010
<img src="/profile.jpg" alt="Chen Yang" class="w-48 h-48 md:w-56 md:h-56 rounded-full object-cover mx-auto md:mx-0 mb-6 md:mb-0 shadow-lg ring-4 ring-gray-300 ring-offset-2 ring-offset-white" loading="lazy" decoding="async" />
1111
<div class="flex-1">
12-
<h1 class="text-5xl font-bold text-gray-900 mb-4">Chen Yang</h1>
12+
<h1 class="text-5xl font-bold text-gray-900 mb-4">
13+
<span class="flex flex-col items-center md:items-start leading-tight">
14+
<span class="inline-flex items-center mb-2">
15+
<img src="/images/杨.svg" alt="" class="h-16 inline-block" loading="lazy" decoding="async" />
16+
<img src="/images/宸.svg" alt="" class="h-16 inline-block ml-1" loading="lazy" decoding="async" />
17+
</span>
18+
<span>Chen Yang</span>
19+
</span>
20+
</h1>
1321
<p class="text-xl text-gray-600 mb-6">CUHK-Shenzhen · Electronic & Computer Engineering · Undergraduate</p>
1422
<p class="text-lg text-gray-700 max-w-3xl md:mx-0 mx-auto leading-relaxed">
1523
I am an undergraduate student at The Chinese University of Hong Kong, Shenzhen, majoring in Electronic & Computer Engineering.
@@ -136,8 +144,8 @@ import Layout from "../layouts/Layout.astro";
136144
<!-- Section Tabs -->
137145
<div class="flex gap-6 mb-8 border-b border-gray-200" id="background-tabs">
138146
<button class="tab-btn px-4 py-2 text-blue-600 border-b-2 border-blue-600 font-medium active" data-tab="education">Education</button>
139-
<button class="tab-btn px-4 py-2 text-gray-600 hover:text-blue-600 transition-colors" data-tab="experience">Experience</button>
140-
<button class="tab-btn px-4 py-2 text-gray-600 hover:text-blue-600 transition-colors" data-tab="service">Service</button>
147+
<button class="tab-btn px-4 py-2 text-gray-600 hover:text-blue-600 transition-colors border-b-2 border-transparent" data-tab="experience">Experience</button>
148+
<button class="tab-btn px-4 py-2 text-gray-600 hover:text-blue-600 transition-colors border-b-2 border-transparent" data-tab="service">Service</button>
141149
</div>
142150

143151
<!-- Experience Items -->

src/styles/global.css

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -108,4 +108,25 @@ section.bg-gray-50 {
108108
/* Smooth transitions for all elements */
109109
a, button, .project-card, header, nav {
110110
transition: all 0.3s ease;
111+
}
112+
113+
/* Local subset webfont for just '楊宸' (place file at /public/fonts/yangchen-kai.woff2) */
114+
@font-face {
115+
font-family: 'YangChenKaiSubset';
116+
src: url('/fonts/yangchen-kai.woff2') format('woff2');
117+
font-weight: 400;
118+
font-style: normal;
119+
font-display: swap;
120+
/* U+694A (楊), U+5BB8 (宸) */
121+
unicode-range: U+694A, U+5BB8;
122+
}
123+
124+
/* Prefer MingLiU/PMingLiU for Traditional Chinese title */
125+
.font-mingliu {
126+
font-family: "Noto Serif TC", "PMingLiU", "MingLiU", "新細明體", "Noto Serif CJK TC", serif;
127+
}
128+
129+
/* Kai style fonts (platform-dependent) */
130+
.font-kai {
131+
font-family: 'YangChenKaiSubset', "LXGW WenKai", "KaiTi", "Kaiti SC", "STKaiti", "DFKai-SB", "BiauKai", "楷体", "楷體", serif;
111132
}

0 commit comments

Comments
 (0)