-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path404.html
More file actions
396 lines (361 loc) · 14.8 KB
/
Copy path404.html
File metadata and controls
396 lines (361 loc) · 14.8 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
396
<!doctype html>
<html lang="zh-TW">
<head>
<meta charset="utf-8">
<title>頁面不存在</title>
<meta http-equiv="refresh" content="3;url=/run-pace-assistant/">
<!-- Fonts: Inter for Numbers/English, Noto Sans TC for Chinese -->
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600;800&family=Noto+Sans+TC:wght@400;500;700&display=swap" rel="stylesheet">
<!-- Lucide Icons -->
<script src="https://unpkg.com/lucide@latest"></script>
<style>
:root {
--bg-color: #050505;
--surface-color: #1A1A1A;
--text-primary: #FFFFFF;
--text-secondary: #A0A0A0;
--accent-color: #00E676;
--danger-color: #FF0000;
--warning-color: #FFC107;
--font-zh: 'Noto Sans TC', sans-serif;
--font-en: 'Inter', sans-serif;
--spacing-sm: 8px;
--spacing-md: 16px;
--spacing-lg: 24px;
--radius: 12px;
}
::-webkit-scrollbar {
width: 6px;
}
::-webkit-scrollbar-track {
background: var(--bg-color);
}
::-webkit-scrollbar-thumb {
background: #444;
border-radius: 10px;
}
::-webkit-scrollbar-thumb:hover {
background: #555;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
input[type="number"]::-webkit-inner-spin-button,
input[type="number"]::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
input[type="number"] { -moz-appearance: textfield; }
body {
margin: 0;
padding: 0;
background-color: var(--bg-color);
color: var(--text-primary);
font-family: var(--font-zh);
overflow: hidden;
height: 100dvh;
}
.view-container {
height: 100%;
display: flex;
flex-direction: column;
opacity: 0;
animation: fadeIn 0.3s forwards;
}
.scroll-content {
flex: 1;
overflow-y: auto;
padding: var(--spacing-lg);
padding-bottom: 0;
}
.bottom-actions {
padding: var(--spacing-lg);
background: linear-gradient(to top, var(--bg-color) 85%, rgba(5,5,5,0));
flex-shrink: 0;
}
@keyframes fadeIn { to { opacity: 1; } }
#author-trigger {
position: fixed;
top: 20px;
right: 20px;
z-index: 100;
cursor: pointer;
color: var(--text-secondary);
background: rgba(255, 255, 255, 0.05);
width: 40px;
height: 40px;
display: flex;
align-items: center;
justify-content: center;
border-radius: 50%;
font-size: 1rem;
transition: all 0.2s ease;
}
#author-trigger:hover {
color: var(--text-primary);
background: rgba(255, 255, 255, 0.1);
}
.lightbox-overlay {
position: fixed;
top: 0;
left: 0;
width: 100%;
height: 100%;
background: rgba(0, 0, 0, 0.85);
backdrop-filter: blur(5px);
z-index: 1000;
display: flex;
align-items: center;
justify-content: center;
opacity: 0;
pointer-events: none;
transition: opacity 0.3s ease;
}
.lightbox-overlay.active {
opacity: 1;
pointer-events: auto;
}
.lightbox-content {
background: var(--surface-color);
border: 1px solid #333;
border-radius: var(--radius);
padding: 30px;
width: 90%;
max-width: 320px;
position: relative;
box-shadow: 0 20px 50px rgba(0,0,0,0.5);
transform: scale(0.9);
transition: transform 0.3s cubic-bezier(0.18, 0.89, 0.32, 1.28);
}
.lightbox-overlay.active .lightbox-content {
transform: scale(1);
}
.lightbox-close {
position: absolute;
top: 12px;
right: 12px;
color: var(--text-secondary);
cursor: pointer;
padding: 4px;
}
.author-links {
display: flex;
flex-direction: column;
gap: 16px;
margin-top: 10px;
}
.author-link-item {
display: flex;
align-items: center;
gap: 12px;
color: var(--text-primary);
text-decoration: none;
padding: 12px;
background: rgba(255, 255, 255, 0.03);
border-radius: 8px;
transition: background 0.2s;
}
.author-link-item:hover {
background: rgba(255, 255, 255, 0.08);
}
.link-icon-img {
width: 20px;
height: 20px;
object-fit: contain;
}
#notification-host {
position: fixed;
top: 20px;
left: 50%;
transform: translateX(-50%);
z-index: 9999;
width: 90%;
max-width: 400px;
pointer-events: none;
}
.notification {
background: rgba(30, 30, 30, 0.95);
backdrop-filter: blur(10px);
border: 1px solid #444;
color: white;
padding: 16px;
border-radius: var(--radius);
margin-bottom: 10px;
display: flex;
align-items: center;
gap: 12px;
box-shadow: 0 10px 30px rgba(0,0,0,0.5);
animation: slideIn 0.3s cubic-bezier(0.18, 0.89, 0.32, 1.28);
}
@keyframes slideIn { from { transform: translateY(-100%); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
.setup-header { margin-bottom: var(--spacing-lg); border-left: 4px solid var(--accent-color); padding-left: var(--spacing-md); }
.setup-header h1 { font-size: 2rem; margin: 0; }
.input-group { margin-bottom: var(--spacing-lg); }
.label-row { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: var(--spacing-sm); }
.input-label { display: flex; align-items: center; gap: 6px; color: var(--text-secondary); font-size: 0.9rem; margin: 0; }
.input-field {
width: 100%;
background: var(--surface-color);
border: 1px solid #333;
color: var(--text-primary);
padding: 16px;
font-size: 1.2rem;
border-radius: var(--radius);
font-family: var(--font-en);
transition: all 0.2s ease;
outline: none;
appearance: none;
-webkit-appearance: none;
-moz-appearance: none;
}
.input-field::-ms-expand {
display: none;
}
.input-field:focus {
border-color: var(--accent-color);
box-shadow: 0 0 0 3px rgba(0, 230, 118, 0.2);
background: #222;
}
.time-inputs { display: flex; gap: var(--spacing-sm); }
.time-inputs input { text-align: center; }
.select-wrapper { position: relative; width: 100%; }
.select-icon {
position: absolute;
right: 16px;
top: 50%;
transform: translateY(-50%);
pointer-events: none;
color: var(--text-secondary);
display: flex;
align-items: center;
}
.feature-intro {
margin-top: 10px;
border: 1px solid #333;
border-radius: var(--radius);
background: rgba(255, 255, 255, 0.03);
overflow: hidden;
}
summary { list-style: none; padding: 16px; cursor: pointer; display: flex; align-items: center; gap: 8px; font-weight: 500; font-size: 0.95rem; }
.intro-content { padding: 0 16px 16px 16px; color: var(--text-secondary); font-size: 0.9rem; line-height: 1.6; }
.intro-content ul { padding-left: 20px; margin: 8px 0; }
.intro-content li { margin-bottom: 4px; }
.main-display {
flex: 1;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
min-height: 200px;
}
.label {
color: var(--text-secondary);
text-transform: uppercase;
letter-spacing: 1px;
margin-bottom: 8px;
font-size: 1rem;
}
.data-primary { font-family: var(--font-en); font-size: 4.5rem; font-weight: 800; line-height: 1; letter-spacing: -2px; }
.data-secondary-group { display: grid; grid-template-columns: 1fr 1fr; gap: var(--spacing-md); width: 100%; margin: 24px 0; }
.data-card { background: var(--surface-color); padding: 20px 10px; border-radius: var(--radius); text-align: center; }
.data-value { font-family: var(--font-en); font-size: 1.8rem; font-weight: 700; }
.summary-header h2 { font-size: 2.5rem; margin: 0; }
.summary-stats { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 10px; margin: 24px 0; }
.stat-item { background: var(--surface-color); padding: 16px 12px; border-radius: var(--radius); text-align: center; }
.stat-item div:last-child { font-family: var(--font-en); font-weight: 700; font-size: 1.2rem; margin-top: 4px; }
.table-container { background: var(--surface-color); border-radius: var(--radius); overflow: hidden; margin-bottom: 24px; }
table { width: 100%; border-collapse: collapse; }
th { background: #252525; color: var(--text-secondary); text-align: left; padding: 12px; font-size: 0.9rem; }
td { padding: 12px; border-top: 1px solid #333; font-family: var(--font-en); font-size: 1rem; }
.row-total { background: rgba(0, 230, 118, 0.1); font-weight: 700; }
.delta-pos { color: var(--danger-color); }
.delta-neg { color: var(--accent-color); }
.btn-group { display: flex; gap: 15px; width: 100%; }
.btn {
border: none; padding: 18px; font-size: 1.1rem; font-weight: 700; border-radius: 50px;
cursor: pointer; font-family: var(--font-zh); width: 100%; display: flex; align-items: center; justify-content: center; gap: 8px;
}
.btn-primary { background-color: var(--accent-color); color: #000; }
.btn-danger { background-color: var(--bg-color); color: var(--danger-color); border: 2px solid var(--danger-color); }
.btn-warning { background-color: var(--warning-color); color: #000; }
.hidden { display: none !important; }
</style>
</head>
<body>
<div id="notification-host"></div>
<!-- 全域作者 Icon -->
<div id="author-trigger">
<i data-lucide="user" size="24"></i>
</div>
<!-- 作者資訊 Lightbox -->
<div id="author-lightbox" class="lightbox-overlay">
<div class="lightbox-content">
<div id="lightbox-close" class="lightbox-close">
<i data-lucide="x" size="24"></i>
</div>
<h3 style="margin-top: 0; margin-bottom: 20px; font-size: 1.2rem;">作者資訊</h3>
<div class="author-links">
<a href="https://forgetfulengineer.github.io" target="_blank" class="author-link-item">
<img src="https://cdn.jsdelivr.net/gh/forgetfulengineer/forgetfulengineer.github.io/img/favicon.svg" alt="icon" class="link-icon-img">
<span>健忘工程師</span>
</a>
<a href="https://github.com/forgetfulengineer" target="_blank" class="author-link-item">
<i data-lucide="github" size="20"></i>
<span>健忘工程師 GitHub</span>
</a>
</div>
</div>
</div>
<!-- 1. 設定畫面 -->
<div id="setup-view" class="view-container">
<div class="scroll-content">
<div class="setup-header">
<h1>跑步配速助手</h1>
<p>自定義目標與語音回報</p>
</div>
<div class="input-group">
<div class="label-row">
<label class="input-label"><i data-lucide="map-pin"></i>目標距離 (公里)</label>
</div>
<input type="number" id="input-dist" class="input-field" placeholder="例如: 5" inputmode="decimal">
</div>
<div class="input-group">
<div class="label-row">
<label class="input-label"><i data-lucide="clock"></i>目標完成時間 (時:分:秒)</label>
<span id="target-pace-preview" style="color: var(--accent-color); font-size: 0.9rem; font-weight: 600;"></span>
</div>
<div class="time-inputs">
<input type="number" id="input-h" class="input-field" placeholder="00">
<input type="number" id="input-m" class="input-field" placeholder="00">
<input type="number" id="input-s" class="input-field" placeholder="00">
</div>
</div>
<div class="input-group">
<div class="label-row">
<label class="input-label"><i data-lucide="volume-2"></i>語音回報間隔</label>
</div>
<div class="select-wrapper">
<select id="input-speech-interval" class="input-field">
<option value="500">每 500 公尺</option>
<option value="1000" selected>每 1 公里</option>
<option value="2000">每 2 公里</option>
</select>
<div class="select-icon"><i data-lucide="chevron-down" size="20"></i></div>
</div>
</div>
<details class="feature-intro">
<summary><i data-lucide="info"></i>功能介紹</summary>
<div class="intro-content">
<p>跑步配速工具。</p>
<ul>
<li>支援自定義目標與語音回報</li>
<li>提供即時數據儀表板與語音播報功能</li>
<li>跑後生成詳細訓練總結(含總里程、平均配速及每公里分段數據分析)</li>
</ul>
<p>協助您精確掌握訓練表現,適合長距離跑步、訓練與比賽使用。</p>
</div>
</details>
</div>
<div class="bottom-actions">
<button id="btn-start" class="btn btn-primary">開始跑步</button>
</div>
</div>
</body>
</html>