databased index text changed title style

This commit is contained in:
aj 2019-06-18 14:58:01 +01:00
parent 2350b12c4c
commit 2aee4aed9a
5 changed files with 18 additions and 23 deletions

View File

@ -3,4 +3,4 @@ from sarsoo import app
app = app app = app
if __name__ == '__main__': if __name__ == '__main__':
app.run() app.run(host='127.0.0.1', port=8080, debug=True)

View File

@ -23,24 +23,20 @@ staticbucketurl = 'https://storage.googleapis.com/sarsooxyzstatic/'
@app.route('/') @app.route('/')
def main(): def main():
index_doc = db.collection(u'pages').document(u'index') index_query = db.collection(u'pages').document(u'index')
doc = index_doc.get() index_dict = index_query.get().to_dict()
index_dict = doc.to_dict()
splashtext = index_dict['splash_text'] main_text = index_dict['main_text']
art = [] art = []
for image in index_dict['art']: for image in index_dict['art']:
art.append(image.get().to_dict()) art.append(image.get().to_dict())
return render_template('index.html', staticroot=staticbucketurl, splash=splashtext, art=art) return render_template('index.html', staticroot=staticbucketurl, art=art, main_text=main_text)
@app.route('/dev') @app.route('/dev')
def dev(): def dev():
return render_template('dev.html') return render_template('dev.html')
if __name__ == '__main__':
app.run(host='127.0.0.1', port=8080, debug=True)
# [END gae_python37_app] # [END gae_python37_app]

View File

@ -4,7 +4,7 @@
<title>sarsoo/{% block title %}{% endblock %}</title> <title>sarsoo/{% block title %}{% endblock %}</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0"> <meta name="viewport" content="width=device-width, initial-scale=1.0">
<link type="text/css" rel="stylesheet" href="{{ url_for('static', filename='style.css') }}"> <link type="text/css" rel="stylesheet" href="{{ url_for('static', filename='style.css') }}">
<link href="https://fonts.googleapis.com/css?family=Megrim|Lato" rel="stylesheet"> <link href="https://fonts.googleapis.com/css?family=Pirata+One|Lato" rel="stylesheet">
<link rel="apple-touch-icon" sizes="180x180" href="https://storage.googleapis.com/sarsooxyzstatic/apple-touch-icon.png"> <link rel="apple-touch-icon" sizes="180x180" href="https://storage.googleapis.com/sarsooxyzstatic/apple-touch-icon.png">
<link rel="icon" type="image/png" sizes="32x32" href="https://storage.googleapis.com/sarsooxyzstatic/favicon-32x32.png"> <link rel="icon" type="image/png" sizes="32x32" href="https://storage.googleapis.com/sarsooxyzstatic/favicon-32x32.png">

View File

@ -10,10 +10,9 @@
<div class="row"> <div class="row">
<div class="col-9" style="text-align:center"> <div class="col-9" style="text-align:center">
<p>electronic engineering student / disney intern</p> {% for text_entry in main_text %}
<p>{{ text_entry }}</p>
<p>proficient in C, Java, Python</p> {% endfor %}
{% if splash %}<p>{{ splash }}</p>{% endif %}
</div> </div>
<div class="col-3 profile"> <div class="col-3 profile">
<img src="{{ staticroot }}me.jpg" height=150> <img src="{{ staticroot }}me.jpg" height=150>

View File

@ -24,8 +24,8 @@ a {
} }
p { p {
color: $text-colour; color: $text-colour;
font-size: 20px; font-size: 20px;
padding: 10px; padding: 10px;
} }
@ -79,7 +79,7 @@ p {
} }
.profile { .profile {
background-color: #131313; background-color: $ui-colour;
height: auto; height: auto;
margin-top: 10px; margin-top: 10px;
/*border: 8px solid #313439;*/ /*border: 8px solid #313439;*/
@ -100,22 +100,22 @@ p {
} }
h1.title { h1.title {
color: white; color: black;
font-size: 6em; font-size: 6em;
font-family: 'Megrim', arial; font-family: 'Pirata One', arial;
text-shadow: 2px 2px 2px #aaa; text-shadow: 3px 3px 3px #aaa;
font-weight: bold; font-weight: bold;
display: block; display: block;
text-decoration: none; text-decoration: none;
background-color: #131313; background-color: white;
padding: 0px; padding: 0px;
/*font-size: 16em;*/ /*font-size: 16em;*/
width: 3em; width: 2.5em;
height: 1.3em; height: 1.3em;
text-align: center; text-align: center;
margin: auto; margin: auto;
box-shadow: 4px 4px 8px #000000; box-shadow: 5px 5px 8px #000000;
} }