start blog work
Signed-off-by: Nyx Tutt <me@everypizza.im>
This commit is contained in:
parent
b0891138d2
commit
0380d5ab4c
6 changed files with 66 additions and 0 deletions
19
site/app.py
19
site/app.py
|
@ -70,6 +70,13 @@ def particleJs():
|
||||||
response.mimetype = "text/javascript"
|
response.mimetype = "text/javascript"
|
||||||
return response
|
return response
|
||||||
|
|
||||||
|
@app.route('/assets/birds.js')
|
||||||
|
def birdJs():
|
||||||
|
js = render_template('assets/scripts/birds.js')
|
||||||
|
response = make_response(js)
|
||||||
|
response.mimetype = "text/javascript"
|
||||||
|
return response
|
||||||
|
|
||||||
@app.route('/assets/three.min.js')
|
@app.route('/assets/three.min.js')
|
||||||
def threeJs():
|
def threeJs():
|
||||||
js = render_template('assets/scripts/three.min.js')
|
js = render_template('assets/scripts/three.min.js')
|
||||||
|
@ -84,6 +91,13 @@ def vantaNetJs():
|
||||||
response.mimetype = "text/javascript"
|
response.mimetype = "text/javascript"
|
||||||
return response
|
return response
|
||||||
|
|
||||||
|
@app.route('/assets/vanta.birds.min.js')
|
||||||
|
def vantaBirdsJs():
|
||||||
|
js = render_template('assets/scripts/vanta.birds.min.js')
|
||||||
|
response = make_response(js)
|
||||||
|
response.mimetype = "text/javascript"
|
||||||
|
return response
|
||||||
|
|
||||||
@app.route('/static/assets/88x31s/<path:filename>')
|
@app.route('/static/assets/88x31s/<path:filename>')
|
||||||
def serve_dir(filename):
|
def serve_dir(filename):
|
||||||
directory = 'templates/assets/88x31s'
|
directory = 'templates/assets/88x31s'
|
||||||
|
@ -93,5 +107,10 @@ def serve_dir(filename):
|
||||||
def todo():
|
def todo():
|
||||||
return render_template('todo.html')
|
return render_template('todo.html')
|
||||||
|
|
||||||
|
@app.route('/blog')
|
||||||
|
@app.route('/blog/')
|
||||||
|
def blog():
|
||||||
|
return render_template('blog/index.j2')
|
||||||
|
|
||||||
if __name__ == '__main__':
|
if __name__ == '__main__':
|
||||||
app.run(host="0.0.0.0", port=8080)
|
app.run(host="0.0.0.0", port=8080)
|
||||||
|
|
|
@ -35,3 +35,12 @@ body {
|
||||||
height: 100%;
|
height: 100%;
|
||||||
z-index: -1;
|
z-index: -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#bird-canvas {
|
||||||
|
position: fixed;
|
||||||
|
top: 0;
|
||||||
|
left: 0;
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
z-index: -1;
|
||||||
|
}
|
||||||
|
|
12
site/templates/assets/scripts/birds.js
Normal file
12
site/templates/assets/scripts/birds.js
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
VANTA.BIRDS({
|
||||||
|
el: "#bird-canvas",
|
||||||
|
mouseControls: true,
|
||||||
|
touchControls: true,
|
||||||
|
gyroControls: false,
|
||||||
|
minHeight: 200.00,
|
||||||
|
minWidth: 200.00,
|
||||||
|
scale: 1.00,
|
||||||
|
scaleMobile: 1.00,
|
||||||
|
backgroundColor: 0x0,
|
||||||
|
quantity: 4.00
|
||||||
|
})
|
1
site/templates/assets/scripts/vanta.birds.min.js
vendored
Normal file
1
site/templates/assets/scripts/vanta.birds.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
22
site/templates/blog/index.j2
Normal file
22
site/templates/blog/index.j2
Normal file
|
@ -0,0 +1,22 @@
|
||||||
|
<!DOCTYPE html>
|
||||||
|
|
||||||
|
<head>
|
||||||
|
<title>
|
||||||
|
Nyx's personal site
|
||||||
|
</title>
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
|
<link href="/assets/index.css" rel="stylesheet" type="text/css">
|
||||||
|
<script src="/assets/three.min.js"></script>
|
||||||
|
<script src="/assets/vanta.birds.min.js"></script>
|
||||||
|
<script src="/assets/birds.js" defer></script>
|
||||||
|
</head>
|
||||||
|
|
||||||
|
<body>
|
||||||
|
<div id="bird-canvas"></div>
|
||||||
|
<h1>
|
||||||
|
nyxblog
|
||||||
|
</h1>
|
||||||
|
<p>
|
||||||
|
welcome to this one's blog! it doesn't have anything on here yet.
|
||||||
|
</p>
|
||||||
|
</body>
|
|
@ -83,6 +83,9 @@
|
||||||
<li>
|
<li>
|
||||||
<a href="todo">to-do list</a>
|
<a href="todo">to-do list</a>
|
||||||
</li>
|
</li>
|
||||||
|
<li>
|
||||||
|
<a href="blog/">blog</a> (this one hasn't made any posts yet though)
|
||||||
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</p>
|
</p>
|
||||||
<h2>
|
<h2>
|
||||||
|
|
Loading…
Add table
Reference in a new issue