-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
395 lines (348 loc) · 18.5 KB
/
index.html
File metadata and controls
395 lines (348 loc) · 18.5 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
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
<!DOCTYPE html>
<html lang="zh-CN">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Slatyfish | Digital Garden</title>
<link href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0/css/all.min.css" rel="stylesheet">
<style>
/* =========================================
1. 核心变量
========================================= */
:root {
--primary-color: #2c3e50;
--accent-color: #0984e3;
--text-main: #2d3436;
--text-sub: #636e72;
--glass-bg: linear-gradient(135deg, rgba(255, 255, 255, 0.65), rgba(255, 255, 255, 0.35));
--glass-bg-hover: linear-gradient(135deg, rgba(255, 255, 255, 0.8), rgba(255, 255, 255, 0.5));
--glass-border: 1px solid rgba(255, 255, 255, 0.45);
}
/* =========================================
2. 整体布局 & 滑动机制
========================================= */
body {
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
margin: 0; padding: 0;
height: 100vh; width: 100vw;
overflow: hidden;
background-image: url('images/background.png');
background-size: cover; background-position: center;
background-color: #dfe6e9;
}
.app-wrapper {
display: flex;
width: 200vw;
height: 100vh;
transition: transform 0.6s cubic-bezier(0.25, 0.8, 0.25, 1);
will-change: transform;
}
.app-wrapper.show-comments {
transform: translateX(-100vw);
}
.page-slide {
width: 100vw;
height: 100vh;
display: flex;
align-items: center;
justify-content: center;
flex-shrink: 0;
position: relative;
}
.main-container {
width: 90vw; max-width: 1200px; height: 90vh;
display: grid;
grid-template-columns: 410px 1fr;
gap: 25px;
}
/* =========================================
3. 左侧栏 (Sidebar)
========================================= */
.sidebar {
display: flex; flex-direction: column; gap: 18px;
overflow-y: auto; padding-right: 5px;
}
.sidebar::-webkit-scrollbar { width: 0; }
/* =========================================
4. 右侧栏 (Content)
========================================= */
.content-area {
background: rgba(255, 255, 255, 0.5);
backdrop-filter: blur(20px);
border: var(--glass-border);
border-radius: 24px;
padding: 40px;
display: flex; flex-direction: column; overflow: hidden;
box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.05);
}
.timeline-scroll-container {
flex: 1; overflow-y: auto; padding-right: 15px; margin-top: 20px;
}
.timeline-scroll-container::-webkit-scrollbar { width: 6px; }
.timeline-scroll-container::-webkit-scrollbar-thumb { background: rgba(0,0,0,0.1); border-radius: 3px; }
/* =========================================
5. 卡片样式 (通用)
========================================= */
.glass-card {
background: var(--glass-bg);
backdrop-filter: blur(24px);
border: var(--glass-border);
border-radius: 20px;
padding: 24px;
transition: all 0.3s;
box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.6), 0 4px 20px 0 rgba(0,0,0,0.05);
}
.sidebar .glass-card:hover {
background: var(--glass-bg-hover);
box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.8), 0 10px 30px 0 rgba(0,0,0,0.1);
}
.hero-card { display: flex; align-items: center; gap: 20px; }
.hero-avatar { width: 75px; height: 75px; border-radius: 50%; object-fit: cover; border: 3px solid #fff; }
.hero-info h1 { margin: 0; font-size: 1.6em; color: var(--primary-color); }
.hero-info p { margin: 4px 0 0 0; color: var(--text-sub); font-size: 0.9em; font-weight: 500; }
.location-tag { margin-top: 8px; font-size: 0.85em; color: #636e72; display: flex; align-items: center; gap: 6px; }
.location-tag i { color: var(--accent-color); }
.social-icons { margin-top: 12px; }
.social-icons a { color: var(--text-main); margin-right: 15px; font-size: 1.1em; transition: color 0.2s;}
.social-icons a:hover { color: var(--accent-color); }
.card-title {
font-size: 0.85em; letter-spacing: 1px; color: #888; font-weight: 700;
margin-bottom: 15px; text-transform: uppercase;
display: flex; align-items: center; gap: 8px;
border-bottom: 2px solid rgba(44, 62, 80, 0.2); padding-bottom: 10px;
}
.bio-list { display: flex; flex-direction: column; gap: 10px; }
.bio-item { font-size: 0.9em; line-height: 1.6; color: #444; display: flex; align-items: baseline; gap: 8px; }
.bio-item i { width: 16px; color: var(--text-sub); opacity: 0.7; font-size: 0.9em; }
.hl { background: rgba(9, 132, 227, 0.1); color: #0984e3; padding: 0 4px; border-radius: 4px; font-weight: 600; margin: 0 2px; }
.hl-p { background: rgba(108, 92, 231, 0.1); color: #6c5ce7; padding: 0 4px; border-radius: 4px; font-weight: 600; margin: 0 2px; }
.spoiler {
background-color: #2d3436; color: transparent; padding: 0 6px; border-radius: 4px;
cursor: pointer; transition: all 0.3s ease; user-select: none; margin: 0 2px;
}
.spoiler:hover { background-color: rgba(108, 92, 231, 0.15); color: #6c5ce7; font-weight: 600; }
/* =========================================
6. Timeline & 评论区样式
========================================= */
.timeline-header { margin-bottom: 10px; display: flex; justify-content: space-between; align-items: center; }
.timeline-header h2 { margin: 0; font-size: 1.5em; color: var(--primary-color); }
.badge-count { background: #fff; padding: 2px 10px; border-radius: 12px; font-size: 0.8em; color: var(--text-sub); font-weight: bold; }
.timeline-item {
margin-bottom: 20px; padding: 25px;
background: rgba(255,255,255,0.4); border-radius: 16px; border: 1px solid rgba(255,255,255,0.3);
transition: all 0.3s;
}
.timeline-item:hover { background: rgba(255,255,255,0.6); transform: translateX(5px); }
.item-meta { display: flex; justify-content: space-between; margin-bottom: 10px; font-size: 0.85em; }
.date { color: var(--text-sub); font-family: monospace; }
.tag { padding: 2px 8px; border-radius: 4px; font-weight: 700; }
.tag.tech { background: rgba(9, 132, 227, 0.1); color: #0984e3; }
.tag.think { background: rgba(230, 126, 34, 0.1); color: #d35400; }
.item-title a { font-size: 1.2em; font-weight: 700; color: var(--primary-color); text-decoration: none; display: block; margin-bottom: 8px; }
.item-title a:hover { color: var(--accent-color); }
.item-excerpt { font-size: 0.95em; color: #555; line-height: 1.6; margin: 0; }
.comments-container {
width: 70vw; max-width: 900px; height: 85vh;
background: rgba(255, 255, 255, 0.65);
backdrop-filter: blur(25px);
border: var(--glass-border);
border-radius: 24px;
padding: 40px;
display: flex; flex-direction: column;
box-shadow: 0 15px 50px rgba(0,0,0,0.1);
}
.giscus-frame { flex: 1; overflow-y: auto; margin-top: 20px; padding-right: 10px; }
.giscus-frame::-webkit-scrollbar { width: 6px; }
.giscus-frame::-webkit-scrollbar-thumb { background: rgba(0,0,0,0.2); border-radius: 3px; }
/* =========================================
7. 导航按钮 (UPDATED)
========================================= */
.nav-btn {
position: absolute; top: 50%; transform: translateY(-50%);
width: 50px; height: 50px; /* 默认圆形 */
background: rgba(255,255,255,0.8);
border-radius: 30px; /* 改为圆角矩形适应展开 */
display: flex; align-items: center; justify-content: center;
font-size: 1.5rem; color: var(--primary-color);
border: 1px solid rgba(255,255,255,0.8);
cursor: pointer;
box-shadow: 0 5px 15px rgba(0,0,0,0.1);
z-index: 100;
overflow: hidden; /* 隐藏未展开的文字 */
/* 关键动画属性 */
transition: width 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275),
background 0.3s,
transform 0.3s,
box-shadow 0.3s;
}
/* 悬停时的展开效果 */
.nav-btn:hover {
width: 140px; /* 展开宽度以容纳文字 */
background: #fff;
color: var(--accent-color);
box-shadow: 0 8px 25px rgba(9, 132, 227, 0.25);
}
/* 文字标签样式 */
.nav-label {
max-width: 0;
opacity: 0;
white-space: nowrap;
font-size: 1rem;
font-weight: 600;
letter-spacing: 1px;
transition: all 0.3s ease;
}
/* 悬停时文字出现 */
.nav-btn:hover .nav-label {
max-width: 100px;
opacity: 1;
margin-right: 10px; /* 文字和箭头之间的间距 */
}
.to-comments-btn { right: 3vw; }
.to-home-btn { left: 3vw; }
@media (max-width: 900px) {
body { height: auto; overflow-y: auto; padding: 0; overflow-x: hidden; }
.app-wrapper { width: 100vw; flex-direction: column; transform: none !important; height: auto; }
.page-slide { width: 100vw; height: auto; padding: 20px 0; }
.main-container { display: flex; flex-direction: column; height: auto; width: 95vw; }
.comments-container { width: 90vw; height: 600px; }
.nav-btn { display: none; }
}
</style>
</head>
<body>
<div class="app-wrapper" id="appWrapper">
<div class="page-slide">
<div class="main-container">
<aside class="sidebar">
<div class="glass-card hero-card">
<img src="images\avatar.jpg" alt="Avatar" class="hero-avatar">
<div class="hero-info">
<h1>Slatyfish</h1>
<p>兵器科学与技术硕士在读</p>
<div class="location-tag">
<i class="fas fa-map-marker-alt"></i> 西安 / 永州
</div>
<div class="social-icons">
<a href="https://github.com/Slatyfish"><i class="fab fa-github"></i></a>
<a href="mailto:2530943724@qq.com"><i class="fas fa-envelope"></i></a>
<a href="#"><i class="fas fa-rss"></i></a>
</div>
</div>
</div>
<div class="glass-card">
<div class="card-title"><i class="fas fa-wrench"></i> 研究(搬砖)</div>
<div class="bio-list">
<div class="bio-item" style="align-items: flex-start;">
<i class="fas fa-microscope" style="margin-top: 5px;"></i>
<span>主攻:<span class="hl">点云匹配</span>、<span class="hl">3D视觉</span>、<span class="hl">SLAM</span></span>
</div>
<div class="bio-item">
<i class="fas fa-code"></i>
<span>Learning:<span class="hl">C++&SLAM</span> 基础补强修炼中...🔨</span>
</div>
</div>
</div>
<div class="glass-card">
<div class="card-title"><i class="fas fa-gamepad"></i> 兴趣爱好</div>
<div class="bio-list">
<div class="bio-item">
<i class="fas fa-ghost"></i>
<span>核心玩家<span class="spoiler">(魂老嗨)</span>、独立游戏爱好者<span class="spoiler">(樱桃社的🐕)</span></span>
</div>
<div class="bio-item">
<i class="fas fa-car"></i>
<span><span class="hl-p">数码</span> 与 <span class="hl-p">汽车</span> 爱好者</span>
</div>
<div class="bio-item">
<i class="fas fa-music"></i>
<span>音乐杂食:近期爱听 <span class="hl-p">器乐摇滚</span> & <span class="hl-p">后摇</span></span>
</div>
<div class="bio-item">
<i class="fas fa-book-open"></i>
<span>尝试:<span class="hl-p">看书</span>、自然风光、<span class="hl-p">旅行</span></span>
</div>
<div class="bio-item">
<i class="fas fa-tv"></i>
<span><span class="spoiler">搞点二次元</span></span>
</div>
</div>
</div>
<div class="glass-card" style="padding: 30px 40px; display: flex; flex-direction: column; gap: 10px;">
<div style="font-size: 1.1em; color: #2d3436; font-weight: 600; letter-spacing: 1px;">
“我们必须想象西西弗斯是幸福的”
</div>
<div style="font-size: 0.9em; color: #888; font-family: Georgia, serif; font-style: italic;">
Il faut imaginer Sisyphe heureux.
</div>
<div style="text-align: right; margin-top: 15px; font-size: 0.85em; color: var(--accent-color); font-weight: bold;">
<span style="opacity:0.5; margin-right:5px;">—</span> Albert Camus
</div>
</div>
</aside>
<main class="content-area">
<div class="timeline-header">
<h2>Timeline</h2>
<span class="badge-count">Latest</span>
</div>
<div class="timeline-scroll-container">
<div class="timeline-item">
<div class="item-meta">
<span class="date">2026-01-18</span>
<span class="tag think">THINK</span>
</div>
<div class="item-title">
<a href="posts/hello_blog.html">print("Hello blog")</a>
</div>
<p class="item-excerpt">近几年越来越觉得自己像永远在推巨石的西西弗斯,读大学、卷绩点、保研、读研……似乎每达成一个节点之后都没有那种明显的成就感,而随之而来的是下一轮巨石滚下山坡...</p>
</div>
</div>
</main>
</div>
<div class="nav-btn to-comments-btn" onclick="toggleView('comments')" title="前往评论区">
<span class="nav-label">评论区</span>
<i class="fas fa-chevron-right"></i>
</div>
</div>
<div class="page-slide">
<div class="nav-btn to-home-btn" onclick="toggleView('home')" title="返回主页">
<i class="fas fa-chevron-left"></i>
</div>
<div class="comments-container">
<div class="timeline-header" style="border-bottom: 2px solid rgba(44,62,80,0.1); padding-bottom: 15px;">
<h2>Guestbook / Comments</h2>
<span class="badge-count" style="background: rgba(9,132,227,0.1); color: #0984e3;">GISCUS</span>
</div>
<div class="giscus-frame">
<div class="giscus"></div>
<script src="https://giscus.app/client.js"
data-repo="Slatyfish/Slatyfish.github.io"
data-repo-id="R_kgDOQ7somQ"
data-category="General"
data-category-id="DIC_kwDOQ7somc4C1GqK"
data-mapping="pathname"
data-strict="0"
data-reactions-enabled="1"
data-emit-metadata="0"
data-input-position="bottom"
data-theme="catppuccin_latte"
data-lang="zh-CN"
crossorigin="anonymous"
async>
</script>
</div>
</div>
</div>
</div>
<script>
function toggleView(view) {
const wrapper = document.getElementById('appWrapper');
if (view === 'comments') {
wrapper.classList.add('show-comments');
} else {
wrapper.classList.remove('show-comments');
}
}
</script>
</body>
</html>