recipes/backend/templates/base_with_header.html

38 lines
No EOL
1.3 KiB
HTML

{% extends "base.html" %}
{% block body_container %}
<div class="header-container">
{% include "title.html" %}
{% match user %}
{% when Some with (user) %}
<a class="create-recipe" href="/recipe/new" >{{ tr.t(Sentence::CreateNewRecipe) }}</a>
<span><a href="/user/edit">
{% if user.name == "" %}
{{ user.email }}
{% else %}
{{ user.name }}
{% endif %}
</a> / <a href="/signout" />{{ tr.t(Sentence::SignOut) }}</a></span>
{% when None %}
<span>
<a href="/signin" >{{ tr.t(Sentence::SignInMenu) }}</a>/<a href="/signup">{{ tr.t(Sentence::SignUpMenu) }}</a>/<a href="/ask_reset_password">{{ tr.t(Sentence::LostPassword) }}</a>
</span>
{% endmatch %}
<select id="select-website-language">
{% for lang in translation::available_languages() %}
<option value="{{ lang.0 }}"
{%+ if tr.current_lang_code() == lang.0 %}
selected
{% endif %}
>{{ lang.1 }}</option>
{% endfor %}
</select>
</div>
<div class="main-container">
{% block main_container %}{% endblock %}
</div>
{% endblock %}