Add base jinja template.

This commit is contained in:
Sage Vaillancourt 2022-09-23 18:55:45 -04:00
parent fb54a9c2e0
commit 17494ca4df
2 changed files with 28 additions and 16 deletions

View File

@ -0,0 +1,22 @@
<!DOCTYPE html>
<html lang="en">
<head>
<title>{% block title %}UnderCover{% endblock title %}</title>
<link rel="stylesheet" type="text/css" href="{{ url_for('static', filename='styles_min.css') }}">
<link rel="icon" href="{{ url_for('static', filename='favicon.png') }}" />
<meta name="viewport" content="user-scalable=no; width=device-width">
{% block head %}{{ head }}{% endblock head %}
</head>
<body>
<a href="/" style="text-decoration: none;">
<h1><span class="logo left">Under</span><span class="logo right">Cover</span></h1>
</a>
<h2>The secret cover letter generator</h2>
{% block content %}
{{ content }}
{% endblock content %}
</body>
</html>

View File

@ -1,12 +1,8 @@
<!doctype html>
<html lang="en">
{% extends "base.jinja2" %}
<head>
<title>UnderCover</title>
<link rel="stylesheet" type="text/css" href="{{ url_for('static', filename='styles_min.css') }}">
<link rel="icon" href="{{ url_for('static', filename='favicon.png') }}" />
<meta name="viewport" content="user-scalable=no; width=device-width">
{% block title %}UnderCover{% endblock %}
{% block head %}
<script type="text/javascript">
window.onload = () => {
{% if errors %}
@ -34,13 +30,9 @@
e.parentNode.removeChild(e)
}
</script>
</head>
{% endblock head %}
<body>
<a href="/" style="text-decoration: none;">
<h1><span class="logo left">Under</span><span class="logo right">Cover</span></h1>
</a>
<h2>The secret cover letter generator</h2>
{% block content %}
{% if username %}
<div class="user logged-in">
<p>You are logged in as {{ username }}</p>
@ -99,6 +91,4 @@
{% endif %}
>Generate PDF</a>
</form>
</body>
</html>
{% endblock content %}