-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
244 lines (227 loc) · 9.65 KB
/
index.html
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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="google-site-verification" content="h_UJGKgFkCd6PHtThOsETygujb2g9q5ku4hR0n1i2K0">
<meta name="description" content="Leon's personal website on GitHub">
<meta name="keywords" content="Leon, personal, website, GitHub, PhantomZone, Forever, Junior, Dev">
<meta name="author" content="Leon Li">
<meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1">
<title>Forever Junior Dev</title>
<link rel="shortcut icon" href="favicon.ico">
<link rel="stylesheet" href="css/index.css">
<script defer src="js/jquery-3.6.1.min.js"></script>
<script defer src="js/paper-full-0.12.15.min.js"></script>
<script defer src="js/index.js"></script>
</head>
<body>
<audio preload loop style="display: none;">
<source src="media/soundOfSeagulls.mp3" type="audio/mpeg">
</audio>
<div class="marine-snow">
<div class="marine-snow-caption">
<p>
Deep sea, the inner frontier.
</p>
<p>
Sunlight stops completely at one thousand meters, but there is rarely any light beyond two hundred meters.
At that depth, you wouldn't be able to see your hands even if you hold them right in front of your eyes.
</p>
<p>
However, if you were able to see anything, apart from the occasional critters, it'd be white particles
patiently showering down from above.
</p>
<p>
It's known as <a href="https://en.wikipedia.org/wiki/Marine_snow" target="_blank" rel="noopener"><i>marine snow</i></a>.
</p>
</div>
<div class="snow layer-1 half"></div>
<div class="snow layer-1"></div>
<div class="snow layer-2 half"></div>
<div class="snow layer-2"></div>
<div class="snow layer-3 half"></div>
<div class="snow layer-3"></div>
</div>
<div class="midnight" style="position:absolute;z-index:8888;top:0;left:0;width:100vw;height:100vh;background-color:#000d1f;"></div>
<figure id="trio">
<img src="images/trio.jpg" alt="A Trio of Three">
<figcaption>Me with a tan and friends at <a href="https://goo.gl/maps/GUSLV1DvbVrsRkiy6" target="_blank" rel="noopener">Panglao</a></figcaption>
</figure>
<div class="mask"></div>
<div id="body-wrap">
<img id="diver-ascent" src="images/diver_ascent.png" alt="Ascending Diver">
<img id="diver-descent" src="images/diver_descent.png" alt="Descending Diver">
<img id="buoy-mobile" src="images/buoy_mobile.png" alt="Buoy">
<div id="header">
<button id="mute-audio">AUDIO ON</button>
<div id="skyline"></div>
<canvas resize="true" hidpi="off" id="canvas-ripple"></canvas>
<div class="sky-gradient"></div>
<div class="rainbow-mask">
<div class="rainbow"></div>
</div>
<img id="cloud" src="images/cloud.svg" alt="Cloud">
<img id="cloud-mobile" src="images/cloud.png" alt="Cloud">
<div id="title-wrap">
<span id="title">Forever Junior Dev</span>
<span id="subtitle">Full Process Front-end Developer</span>
</div>
<img id="fish-1" class="flying-obj" src="images/flying_fish_left.png" alt="Flying Fish">
<img id="fish-2" class="flying-obj" src="images/flying_fish_right.png" alt="Flying Fish">
<img id="dolphin" class="flying-obj" src="images/jumping_dolphins.png" alt="Jumping Dolphins">
<img id="fish-4" class="flying-obj" src="images/flying_fish_right.png" alt="Flying Fish">
<img id="seagulls" class="flying-obj" src="images/flock-of-seagulls.png" alt="A Flock of Seagulls">
</div>
<div id="content">
<nav>
<div id="nav-el-wrap">
<img id="nav-buoy" src="images/buoy.png" alt="Free Diving Buoy">
<div id="mark" title="My personal best so far, 35 meters"></div>
<div id="guideline"></div>
<ul id="nav-up">
<li><span>10m</span><a href="#moi">Moi</a></li>
<li><span>20m</span><a href="#projects">Projects</a></li>
<li><span>30m</span><a href="#dive">Dive! Dive!</a></li>
<li><span>40m</span><a href="#stars">The Stars</a></li>
<li><span>50m</span><a href="#life">C'est la vie</a></li>
</ul>
<ul id="nav-down">
<li><span>130m</span><a href="#records">WR 2018</a></li>
</ul>
<img id="bottom-plate" src="images/bottom_plate.png" alt="Bottom Plate">
</div>
<a id="pi-symbol" href="#pi">π</a>
</nav>
<main>
<div id="guideline-mobile-up"></div>
<article></article>
</main>
<img id="swordfish" src="images/swordfish.png" alt="Swordfish">
<img id="jellyfish" src="images/jellyfish.png" alt="Jellyfish">
</div>
<div id="footer-mobile">
<ul id="nav-mobile">
<li><a href="#moi">Moi</a></li>
<li><a href="#projects">Projects</a></li>
<li><a href="#dive">Dive! Dive!</a></li>
<li><a href="#stars">The Stars</a></li>
<li><a href="#life">C'est la vie</a></li>
<li><a href="#records">WR 2018</a></li>
</ul>
<ul id="nav-mobile">
<li><a href="#moi">10m</a></li>
<li><a href="#projects">20m</a></li>
<li><a href="#dive">30m</a></li>
<li><a href="#stars">40m</a></li>
<li><a href="#life">50m</a></li>
<li><a href="#records">130m</a></li>
</ul>
<div id="guideline-mobile-down">
<div id="guideline-mobile-down-line"></div>
<img src="images/bottom_plate.png" alt="Bottom Plate">
<div id="mark-mobile" title="My personal best so far, 35 meters"></div>
</div>
</div>
<div id="motto">
<span>Follow your heart, always.</span>
<a href="#pi">π</a>
</div>
</div>
<script type="text/paperscript" canvas="canvas-ripple">
var values = {
friction: 0.8,
timeStep: 0.01,
amount: 15,
mass: 2,
count: 0
};
values.invMass = 1 / values.mass;
var path, springs;
var size = view.size * [1.2, 1];
var Spring = function(a, b, strength, restLength) {
this.a = a;
this.b = b;
this.restLength = restLength || 80;
this.strength = strength ? strength : 0.55;
this.mamb = values.invMass * values.invMass;
};
Spring.prototype.update = function() {
var delta = this.b - this.a;
var dist = delta.length;
var normDistStrength = (dist - this.restLength) / (dist * this.mamb) * this.strength;
delta.y *= normDistStrength * values.invMass * 0.2;
if (!this.a.fixed)
this.a.y += delta.y;
if (!this.b.fixed)
this.b.y -= delta.y;
};
function createPath(strength) {
var path = new Path({
fillColor: '#00aef0'
});
springs = [];
for (var i = 0; i <= values.amount; i++) {
var segment = path.add(new Point(i / values.amount, 0.5) * size);
var point = segment.point;
if (i == 0 || i == values.amount)
point.y += size.height;
point.px = point.x;
point.py = point.y;
// The first two and last two points are fixed:
point.fixed = i < 2 || i > values.amount - 2;
if (i > 0) {
var spring = new Spring(segment.previous.point, point, strength);
springs.push(spring);
}
}
path.position.x -= size.width / 4;
return path;
}
function onResize() {
if (path)
path.remove();
size = view.bounds.size * [2, 1];
path = createPath(0.1);
}
function onMouseMove(event) {
var location = path.getNearestLocation(event.point);
var segment = location.segment;
var point = segment.point;
if (!point.fixed && location.distance < size.height / 4) {
var y = event.point.y;
point.y += (y - point.y) / 6;
if (segment.previous && !segment.previous.fixed) {
var previous = segment.previous.point;
previous.y += (y - previous.y) / 24;
}
if (segment.next && !segment.next.fixed) {
var next = segment.next.point;
next.y += (y - next.y) / 24;
}
}
}
function onFrame(event) {
updateWave(path);
}
function updateWave(path) {
var force = 1 - values.friction * values.timeStep * values.timeStep;
for (var i = 0, l = path.segments.length; i < l; i++) {
var point = path.segments[i].point;
var dy = (point.y - point.py) * force;
point.py = point.y;
point.y = Math.max(point.y + dy, 0);
}
for (var j = 0, l = springs.length; j < l; j++) {
springs[j].update();
}
path.smooth({ type: 'continuous' });
}
/*function onKeyDown(event) {
if (event.key == 'space') {
path.fullySelected = !path.fullySelected;
path.fillColor = path.fullySelected ? null : 'black';
}
}*/
</script>
</body>
</html>