Skip to content

Commit 483ba97

Browse files
committed
Update
1 parent 51014fb commit 483ba97

File tree

5 files changed

+65
-13
lines changed

5 files changed

+65
-13
lines changed

docs/assets/javascripts/comments.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
s.setAttribute("data-emit-metadata", "0");
2727
s.setAttribute("data-input-position", "top");
2828
s.setAttribute("data-theme", getTheme());
29-
s.setAttribute("data-lang", "zh-CN");
29+
s.setAttribute("data-lang", "en");
3030
s.setAttribute("data-loading", "lazy");
3131
s.setAttribute("crossorigin", "anonymous");
3232
s.setAttribute("async", "");

docs/index.md

Lines changed: 52 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -12,24 +12,68 @@ comments: true
1212

1313
=== "English"
1414

15-
- An undergraduate student at Xidian University, majoring in Computer Science and Technology, with a focus on Software and Theory. Expected to graduate in 2026.
15+
- An undergraduate student at Xidian University, majoring in Computer Science and Technology, with a focus on Software and Theory, expected to graduate in 2026.
1616
- Currently exploring technologies related to game engine development.
1717

1818
=== "中文"
1919

2020
- 西安电子科技大学本科生,计算机科学与技术(软件与理论方向)专业,预计 2026 年毕业。
2121
- 正在学习游戏引擎相关技术。
2222

23-
## Recent Projects
23+
## Recent Works
2424

25-
- [MarchEngine](https://github.com/stalomeow/MarchEngine){target="_blank"}: A game engine based on Direct3D 12, C++17, and .NET 9 for learning purposes.
25+
=== "English"
26+
27+
- [March Engine](https://github.com/stalomeow/MarchEngine){target="_blank"}: A game engine based on Direct3D 12, C++17, and .NET 9 for learning purposes.
28+
29+
![](https://raw.githubusercontent.com/stalomeow/MarchEngine/main/Documentation/Attachments/overview.png)
30+
31+
- [Dream Ticker](https://github.com/stalomeow/DreamTicker){target="_blank"}: A replica of Dream Ticker, an optical illusion-based puzzle game from Honkai: Star Rail 2.0.
32+
33+
![](https://raw.githubusercontent.com/stalomeow/DreamTicker/main/Recordings/Image%20Sequence_001_0000.png)
34+
35+
- [StarRail NPR Shader](https://github.com/stalomeow/StarRailNPRShader){target="_blank"}: Fan-made shaders for Unity URP attempting to replicate the shading of Honkai: Star Rail.
36+
37+
![](https://raw.githubusercontent.com/stalomeow/StarRailNPRShaderDocs/main/docs/assets/banners/en-thumbnail.png){.fancybox-thumbnail}
38+
39+
=== "中文"
40+
41+
- [March Engine](https://github.com/stalomeow/MarchEngine){target="_blank"}:基于 Direct3D 12、C++17 和 .NET 9 的游戏引擎,用于学习目的。
42+
43+
![](https://raw.githubusercontent.com/stalomeow/MarchEngine/main/Documentation/Attachments/overview.png)
44+
45+
- [Dream Ticker](https://github.com/stalomeow/DreamTicker){target="_blank"}:复刻崩坏:星穹铁道 2.0 的视错觉游戏「梦境迷钟」。
46+
47+
![](https://raw.githubusercontent.com/stalomeow/DreamTicker/main/Recordings/Image%20Sequence_001_0000.png)
2648

27-
![](https://raw.githubusercontent.com/stalomeow/MarchEngine/refs/heads/main/Documentation/Attachments/overview.png)
49+
- [StarRail NPR Shader](https://github.com/stalomeow/StarRailNPRShader){target="_blank"}:基于 Unity URP 的仿星穹铁道渲染 Shader。
2850

29-
- [StarRailNPRShader](https://github.com/stalomeow/StarRailNPRShader){target="_blank"}: Fan-made shaders for Unity URP attempting to replicate the shading of Honkai: Star Rail.
51+
![](https://raw.githubusercontent.com/stalomeow/StarRailNPRShaderDocs/main/docs/assets/banners/cn-thumbnail.png){.fancybox-thumbnail}
3052

31-
![](https://raw.githubusercontent.com/stalomeow/StarRailNPRShaderDocs/main/docs/assets/banners/en-thumbnail.png)
53+
## Other Projects
54+
55+
=== "English"
56+
57+
- [Quick Play Mode](https://github.com/stalomeow/QuickPlayMode){target="_blank"}: When entering play mode, automatically resetting static members of dirty types, instead of reloading the domain.
58+
- [Resume Template](https://github.com/stalomeow/resume-template){target="_blank"}: My resume template written in Typst.
59+
- [Traintime PDA](https://github.com/BenderBlog/traintime_pda){target="_blank"}: An open-source personal data assistant for XDU students, with several features contributed by me.
60+
- You can find more projects on my [GitHub](https://github.com/stalomeow){target="_blank"}.
61+
62+
=== "中文"
63+
64+
- [Quick Play Mode](https://github.com/stalomeow/QuickPlayMode){target="_blank"}:进入播放模式时,自动按需重置类型的静态成员,不使用 Domain Reloading。
65+
- [Resume Template](https://github.com/stalomeow/resume-template){target="_blank"}:个人使用的简历模板,使用 Typst 编写。
66+
- [Traintime PDA](https://github.com/BenderBlog/traintime_pda){target="_blank"}:为西电学生设计的开源信息查询软件。我贡献了一些功能。
67+
- 可以访问我的 [GitHub](https://github.com/stalomeow){target="_blank"} 查看更多项目。
68+
69+
## About This Site
70+
71+
=== "English"
72+
73+
This is my notebook and blog. You're welcome to leave a comment.
74+
75+
=== "中文"
3276

33-
<!-- ## Wife
77+
这是我的笔记本和博客。欢迎在评论区留言。
3478

35-
![](assets/castorice.jpg){ width="300" } -->
79+
![](assets/castorice.jpg){ width="300" }

overrides/partials/comments.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
{% if page.meta.comments == true %}
2-
<h2 id="__comments">{{ lang.t("meta.comments") }}</h2>
2+
<h2 id="__comments">Comments</h2>
33
{% endif %}

scripts/fancybox.py

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import json
22
import logging
3+
import posixpath
34
import re
45

56
from mkdocs.plugins import event_priority
@@ -86,22 +87,29 @@ def wrap_img(match: re.Match, skip_class, meta):
8687
caption = re.search(r"alt=[\"]([^\"]+)", img_attr)
8788
caption = caption.group(1) if caption else ""
8889

90+
if "fancybox-thumbnail" in classes:
91+
filename, ext = posixpath.splitext(src)
92+
filename = filename.removesuffix("-thumbnail")
93+
href = filename + ext
94+
else:
95+
href = src
96+
8997
if src.endswith(("#only-dark", "#gh-dark-mode-only")):
9098
theme = "fancybox-only-dark"
9199
elif src.endswith(("#only-light", "#gh-light-mode-only")):
92100
theme = "fancybox-only-light"
93101
else:
94102
theme = ""
95103

96-
a_tag = f'<a href="{src}" data-fancybox data-caption="{caption}">{img_tag}</a>'
104+
a_tag = f'<a href="{href}" data-fancybox data-caption="{caption}">{img_tag}</a>'
97105
return f'<figure {theme}>{a_tag}<figcaption>{caption}</figcaption></figure>'
98106
except Exception as e:
99107
log.warning(f"Error in wrapping img tag with fancybox: {e} {match.group(0)}")
100108
return match.group(0)
101109

102110
def on_page_content(html, page, config, **kwargs):
103111
# skip emoji img with index as class name from pymdownx.emoji https://facelessuser.github.io/pymdown-extensions/extensions/emoji/
104-
skip_class = ["emojione", "twemoji", "gemoji"]
112+
skip_class = ["emojione", "twemoji", "gemoji", "no-fancybox"]
105113
return re.compile(r"<img(?P<attr>.*?)>").sub(lambda match: wrap_img(match, skip_class, page.meta), html)
106114

107115
# 放在 blog 之后执行,更新首页 excerpt 的内容

scripts/sponsor.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ def on_config(config: MkDocsConfig):
2020
return config
2121

2222
def on_nav(nav: Navigation, config: MkDocsConfig, files: Files):
23-
link = Link(title='Sponsor', url=URL)
23+
link = Link(title=TITLE, url=URL)
2424
link.meta = {
2525
'icon': 'material/heart',
2626
'subtitle': 'Buy Me a Coffee',

0 commit comments

Comments
 (0)