Added comment preview functionality to user pages. It works by passing the comment...
[mediagoblin.git] / mediagoblin / templates / mediagoblin / base.html
CommitLineData
76c9ea6b
WKG
1{#
2# GNU MediaGoblin -- federated, autonomous media hosting
cf29e8a8 3# Copyright (C) 2011, 2012 MediaGoblin contributors. See AUTHORS.
76c9ea6b
WKG
4#
5# This program is free software: you can redistribute it and/or modify
6# it under the terms of the GNU Affero General Public License as published by
7# the Free Software Foundation, either version 3 of the License, or
8# (at your option) any later version.
9#
10# This program is distributed in the hope that it will be useful,
11# but WITHOUT ANY WARRANTY; without even the implied warranty of
12# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13# GNU Affero General Public License for more details.
14#
15# You should have received a copy of the GNU Affero General Public License
16# along with this program. If not, see <http://www.gnu.org/licenses/>.
9a5b2da5
CAW
17-#}
18<!doctype html>
a80ebf3b
AL
19<html
20{% block mediagoblin_html_tag %}
21{% endblock mediagoblin_html_tag %}
22>
a0598d5c 23 <head>
5fa35884 24 <meta charset="utf-8">
e58f2599 25 <meta name="viewport" content="width=device-width, initial-scale=1.0">
78801685 26 <title>{% block title %}{{ app_config['html_title'] }}{% endblock %}</title>
1344821d 27 <link rel="stylesheet" type="text/css"
1dc7f28d 28 href="{{ request.staticdirect('/css/extlib/reset.css') }}"/>
8ac897c3
CAW
29 <link rel="stylesheet" type="text/css"
30 href="{{ request.staticdirect('/css/base.css') }}"/>
7a8ad818
CAW
31 <link rel="shortcut icon"
32 href="{{ request.staticdirect('/images/goblin.ico') }}" />
742bfa7a
E
33 <script type="text/javascript"
34 src="{{ request.staticdirect('/js/extlib/jquery.js') }}"></script>
3c912132
CAW
35 <script type="text/javascript"
36 src="{{ request.staticdirect('/js/header_dropdown.js') }}"></script>
2d7b6bde
JW
37 <script type="text/javascript"
38 src="{{ request.staticdirect('/js/notifications.js') }}"></script>
3c912132 39
f6d1d28d 40 {# For clarification, the difference between the extra_head.html template
cac17c15 41 # and the head template hook is that the former should be used by
f6d1d28d
CAW
42 # themes and the latter should be used by plugins.
43 # The reason is that only one thing can override extra_head.html...
44 # but multiple plugins can hook into the template hook.
45 #}
667d1fc8 46 {% include "mediagoblin/extra_head.html" %}
cac17c15 47 {% template_hook("head") %}
0416b866 48
00c39256
BK
49 {% block mediagoblin_head %}
50 {% endblock mediagoblin_head %}
a0598d5c 51 </head>
a0598d5c 52 <body>
8ca51d32 53 {% include 'mediagoblin/bits/body_start.html' %}
a0598d5c
CAW
54 {% block mediagoblin_body %}
55 {% block mediagoblin_header %}
afcb0855 56 <header>
17dcc3ae 57 {%- include "mediagoblin/bits/logo.html" -%}
afcb0855
JS
58 {% block mediagoblin_header_title %}{% endblock %}
59 <div class="header_right">
155438cd 60 {%- if request.user %}
29497982 61 {% if request.user and request.user.status == 'active' %}
2d7b6bde 62
0c7fa755
JW
63 {% set notification_count = request.notifications.get_notification_count(request.user.id) %}
64 {% if notification_count %}
2d7b6bde 65 <a href="#notifications" class="notification-gem button_action" title="Notifications">
0c7fa755
JW
66 {{ notification_count }}</a>
67 {% endif %}
2369feb5
JS
68 <div class="button_action header_dropdown_down">&#9660;</div>
69 <div class="button_action header_dropdown_up">&#9650;</div>
29497982 70 {% elif request.user and request.user.status == "needs_email_verification" %}
afcb0855 71 {# the following link should only appear when verification is needed #}
7b6836a3 72 <a href="{{ request.urlgen('mediagoblin.user_pages.user_home',
29497982 73 user=request.user.username) }}"
afcb0855 74 class="button_action_highlight">
29497982 75 {% trans %}Verify your email!{% endtrans %}</a>
10d24197 76 or <a href="{{ request.urlgen('mediagoblin.auth.logout') }}">{% trans %}log out{% endtrans %}</a>
681e1371 77 {% endif %}
744f1c83 78 {%- elif auth %}
d3c6e2a0
SS
79 <a href="{{ request.urlgen('mediagoblin.auth.login') }}?next={{
80 request.base_url|urlencode }}">
155438cd
E
81 {%- trans %}Log in{% endtrans -%}
82 </a>
83 {%- endif %}
afcb0855 84 </div>
d297d8e8 85 <div class="clear"></div>
a7d079ac 86 {% if request.user and request.user.status == 'active' %}
2369feb5 87 <div class="header_dropdown">
d1d53560
CAW
88 <p>
89 <span class="dropdown_title">
90 {% trans user_url=request.urlgen('mediagoblin.user_pages.user_home',
91 user=request.user.username),
92 user_name=request.user.username -%}
93 <a href="{{ user_url }}">{{ user_name }}</a>'s account
94 {%- endtrans %}
a5b9a066
JS
95 </span>
96 &middot;
97 <a href="{{ request.urlgen('mediagoblin.edit.account') }}">{%- trans %}Change account settings{% endtrans -%}</a>
98 &middot;
99 <a href="{{ request.urlgen('mediagoblin.user_pages.processing_panel',
fe253e31 100 user=request.user.username) }}">
a5b9a066
JS
101 {%- trans %}Media processing panel{% endtrans -%}
102 </a>
103 &middot;
104 <a href="{{ request.urlgen('mediagoblin.auth.logout') }}">{% trans %}Log out{% endtrans %}</a>
d1d53560 105 </p>
a5b9a066 106 <a class="button_action" href="{{ request.urlgen('mediagoblin.submit.start') }}">
5a42915b 107 {%- trans %}Add media{% endtrans -%}
fe253e31 108 </a>
a5b9a066 109 <a class="button_action" href="{{ request.urlgen('mediagoblin.submit.collection') }}">
5a42915b 110 {%- trans %}Create new collection{% endtrans -%}
fe253e31 111 </a>
5a42915b 112 {% if request.user.is_admin %}
a5b9a066
JS
113 <p>
114 <span class="dropdown_title">Admin powers:</span>
115 <a href="{{ request.urlgen('mediagoblin.admin.panel') }}">
116 {%- trans %}Media processing panel{% endtrans -%}
117 </a>
118 </p>
5a42915b 119 {% endif %}
2d7b6bde 120 {% include 'mediagoblin/fragments/header_notifications.html' %}
5a42915b
JS
121 </div>
122 {% endif %}
afcb0855 123 </header>
a0598d5c 124 {% endblock %}
155438cd 125 <div class="container">
8ca51d32 126 {% include 'mediagoblin/bits/above_content.html' %}
155438cd 127 <div class="mediagoblin_content">
741d5a37 128 {% include "mediagoblin/utils/messages.html" %}
f7bcfaff
JS
129 {% block mediagoblin_content %}
130 {% endblock mediagoblin_content %}
155438cd 131 </div>
19968583 132 {%- include "mediagoblin/bits/base_footer.html" %}
155438cd
E
133 </div>
134 {%- endblock mediagoblin_body %}
8ca51d32 135 {% include 'mediagoblin/bits/body_end.html' %}
a0598d5c
CAW
136 </body>
137</html>