-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
226 lines (215 loc) · 8.75 KB
/
Copy pathindex.html
File metadata and controls
226 lines (215 loc) · 8.75 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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Cosmos — Solar System Simulation</title>
<meta
name="description"
content="Interactive Three.js solar system with realistic orbital periods, adjustable time, starfield, and a modern glass HUD."
/>
<meta name="theme-color" content="#05060a" />
<link rel="canonical" href="https://rdsciv.github.io/grokerSolarSystem/" />
<!-- Open Graph -->
<meta property="og:type" content="website" />
<meta property="og:site_name" content="Cosmos" />
<meta property="og:title" content="Cosmos — Solar System Simulation" />
<meta
property="og:description"
content="Interactive Three.js solar system with realistic orbital periods, adjustable time, and a modern glass HUD."
/>
<meta
property="og:url"
content="https://rdsciv.github.io/grokerSolarSystem/"
/>
<meta
property="og:image"
content="https://rdsciv.github.io/grokerSolarSystem/og.png"
/>
<meta property="og:image:width" content="1200" />
<meta property="og:image:height" content="630" />
<!-- Twitter -->
<meta name="twitter:card" content="summary_large_image" />
<meta name="twitter:title" content="Cosmos — Solar System Simulation" />
<meta
name="twitter:description"
content="Interactive Three.js solar system with realistic orbital periods, adjustable time, and a modern glass HUD."
/>
<meta
name="twitter:image"
content="https://rdsciv.github.io/grokerSolarSystem/og.png"
/>
<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=DM+Sans:ital,opsz,wght@0,9..40,300;0,9..40,400;0,9..40,500;0,9..40,600;0,9..40,700;1,9..40,400&family=JetBrains+Mono:wght@400;500&display=swap"
rel="stylesheet"
/>
<link rel="stylesheet" href="/src/style.css" />
</head>
<body>
<div id="app">
<canvas id="canvas"></canvas>
<!-- Top bar -->
<header class="hud-top">
<div class="brand">
<span class="brand-mark"></span>
<div class="brand-text">
<h1>Cosmos</h1>
<p>Solar System Simulation</p>
</div>
</div>
<div class="status-pills">
<div class="pill" id="fps-pill">
<span class="pill-dot live"></span>
<span id="fps-value">60</span> FPS
</div>
<div class="pill" id="time-pill">
<span class="pill-label">Sim date</span>
<span id="sim-date">—</span>
</div>
</div>
</header>
<!-- Left panel: focus / info -->
<aside class="hud-panel hud-left">
<div class="panel-header">
<span class="panel-eyebrow">Focus</span>
<h2 id="focus-name">Sun</h2>
</div>
<div class="info-grid" id="focus-info">
<div class="info-item">
<span class="info-label">Type</span>
<span class="info-value" id="info-type">Star</span>
</div>
<div class="info-item">
<span class="info-label">Radius</span>
<span class="info-value" id="info-radius">696,340 km</span>
</div>
<div class="info-item">
<span class="info-label">Distance</span>
<span class="info-value" id="info-distance">—</span>
</div>
<div class="info-item">
<span class="info-label">Orbital period</span>
<span class="info-value" id="info-period">—</span>
</div>
<div class="info-item">
<span class="info-label">Day length</span>
<span class="info-value" id="info-day">25.4 days</span>
</div>
<div class="info-item">
<span class="info-label">Moons</span>
<span class="info-value" id="info-moons">—</span>
</div>
</div>
<p class="focus-blurb" id="focus-blurb">
The Sun is a G-type main-sequence star at the heart of our solar system,
holding the planets in gravitational embrace.
</p>
</aside>
<!-- Right panel: bodies -->
<aside class="hud-panel hud-right">
<div class="panel-header">
<span class="panel-eyebrow">Bodies</span>
<h2>Navigate</h2>
</div>
<div class="body-list" id="body-list"></div>
</aside>
<!-- Bottom controls -->
<footer class="hud-bottom">
<div class="control-card time-card">
<div class="control-header">
<span class="control-title">Time</span>
<span class="control-value" id="speed-label">1 day / sec</span>
</div>
<div class="time-controls">
<button class="icon-btn" id="btn-pause" title="Pause / Play" aria-label="Pause">
<svg id="icon-pause" width="18" height="18" viewBox="0 0 24 24" fill="currentColor">
<rect x="6" y="5" width="4" height="14" rx="1" />
<rect x="14" y="5" width="4" height="14" rx="1" />
</svg>
<svg id="icon-play" class="hidden" width="18" height="18" viewBox="0 0 24 24" fill="currentColor">
<path d="M8 5.14v13.72a1 1 0 0 0 1.5.86l11-6.86a1 1 0 0 0 0-1.72l-11-6.86a1 1 0 0 0-1.5.86z" />
</svg>
</button>
<button class="icon-btn" id="btn-reset" title="Reset time" aria-label="Reset">
<svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
<path d="M3 12a9 9 0 1 0 3-6.7" stroke-linecap="round" />
<path d="M3 4v5h5" stroke-linecap="round" stroke-linejoin="round" />
</svg>
</button>
<div class="slider-wrap">
<input
type="range"
id="speed-slider"
min="0"
max="100"
value="30"
aria-label="Simulation speed"
/>
<div class="speed-ticks">
<span>Pause</span>
<span>Day</span>
<span>Year</span>
<span>Century</span>
</div>
</div>
<div class="preset-row">
<button class="chip" data-speed="0">0×</button>
<button class="chip" data-speed="1">1×</button>
<button class="chip" data-speed="30">30×</button>
<button class="chip active" data-speed="365">1y</button>
<button class="chip" data-speed="3650">10y</button>
<button class="chip" data-speed="36500">100y</button>
</div>
</div>
</div>
<div class="control-card options-card">
<div class="control-header">
<span class="control-title">Display</span>
</div>
<div class="toggles">
<label class="toggle">
<input type="checkbox" id="toggle-orbits" checked />
<span class="toggle-ui"></span>
<span>Orbits</span>
</label>
<label class="toggle">
<input type="checkbox" id="toggle-labels" checked />
<span class="toggle-ui"></span>
<span>Labels</span>
</label>
<label class="toggle">
<input type="checkbox" id="toggle-trails" />
<span class="toggle-ui"></span>
<span>Trails</span>
</label>
<label class="toggle">
<input type="checkbox" id="toggle-asteroids" checked />
<span class="toggle-ui"></span>
<span>Asteroids</span>
</label>
</div>
</div>
<div class="control-card help-card">
<div class="help-row">
<kbd>Drag</kbd><span>Orbit</span>
<kbd>Scroll</kbd><span>Zoom</span>
<kbd>Right-drag</kbd><span>Pan</span>
</div>
<button class="share-btn" id="btn-share" type="button" title="Copy shareable link (S)">
<svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" aria-hidden="true">
<path d="M4 12v7a1 1 0 0 0 1 1h14a1 1 0 0 0 1-1v-7" stroke-linecap="round" />
<path d="M12 3v12" stroke-linecap="round" />
<path d="M8 7l4-4 4 4" stroke-linecap="round" stroke-linejoin="round" />
</svg>
<span class="share-label">Share</span>
</button>
</div>
</footer>
<!-- Floating labels container -->
<div id="labels" class="labels-layer"></div>
</div>
<script type="module" src="/src/main.js"></script>
</body>
</html>