1
0
Fork 0
mirror of https://gitlab.com/SIGBUS/nyaa.git synced 2024-12-22 19:00:07 +00:00

Unfuck the layout, and remove the search update info from the about box on the home page to declutter.

This commit is contained in:
ReimuHakurei 2017-05-24 04:04:32 +00:00
parent fb91b2bbf8
commit b0b77775d7
3 changed files with 57 additions and 43 deletions

View file

@ -5,8 +5,6 @@
<div class="alert alert-info"> <div class="alert alert-info">
<p><strong>2017-05-22 Update:</strong> We've added comments. You can change your avatar using <a href="http://en.gravatar.com">Gravatar</a> or if you don't like gravatar you can just stick with our spify default avatar.</p> <p><strong>2017-05-22 Update:</strong> We've added comments. You can change your avatar using <a href="http://en.gravatar.com">Gravatar</a> or if you don't like gravatar you can just stick with our spify default avatar.</p>
<p><strong>2017-05-22 Update:</strong> We've updated our upload API to v2 (v1 <b>is now disabled!</b>). See documentation <b><a href="https://github.com/nyaadevs/nyaa/blob/master/utils/api_uploader_v2.py">here</a></b>.</p> <p><strong>2017-05-22 Update:</strong> We've updated our upload API to v2 (v1 <b>is now disabled!</b>). See documentation <b><a href="https://github.com/nyaadevs/nyaa/blob/master/utils/api_uploader_v2.py">here</a></b>.</p>
<p><strong>2017-05-17 Update:</strong> We've added faster and more accurate search! In addition to your typical keyword search in both English and other languages, you can also now use powerful operators
like <kbd>clockwork planet -horrible</kbd> or <kbd>commie|horrible|cartel yowamushi</kbd> to search. For all supported operators, please click <a href="https://www.elastic.co/guide/en/elasticsearch/reference/current/query-dsl-simple-query-string-query.html#_simple_query_string_syntax">here</a>. More features are coming soon!</p><br>
<p>We welcome you to provide feedback at <a href="irc://irc.rizon.net/nyaa-dev">#nyaa-dev@irc.rizon.net</a></p> <p>We welcome you to provide feedback at <a href="irc://irc.rizon.net/nyaa-dev">#nyaa-dev@irc.rizon.net</a></p>
<p>Our GitHub: <a href="https://github.com/nyaadevs" target="_blank">https://github.com/nyaadevs</a> - creating <a href="https://github.com/nyaadevs/nyaa/issues">issues</a> for features and faults is recommendable!</p> <p>Our GitHub: <a href="https://github.com/nyaadevs" target="_blank">https://github.com/nyaadevs</a> - creating <a href="https://github.com/nyaadevs/nyaa/issues">issues</a> for features and faults is recommendable!</p>
</div> </div>

View file

@ -118,11 +118,15 @@
</li> </li>
{% else %} {% else %}
<li class="dropdown"> <li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false"> <a href="#" class="dropdown-toggle visible-lg visible-sm visible-xs" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">
<i class="fa fa-user-times fa-fw"></i> <i class="fa fa-user fa-fw"></i>
Guest Guest
<span class="caret"></span> <span class="caret"></span>
</a> </a>
<a href="#" class="dropdown-toggle hidden-lg hidden-sm hidden-xs" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">
<i class="fa fa-user fa-fw"></i>
<span class="caret"></span>
</a>
<ul class="dropdown-menu"> <ul class="dropdown-menu">
<li> <li>
<a href="/login"> <a href="/login">
@ -192,7 +196,21 @@
{% elif config.SITE_FLAVOR == 'sukebei' %} {% elif config.SITE_FLAVOR == 'sukebei' %}
{% set used_cats = suke_cats %} {% set used_cats = suke_cats %}
{% endif %} {% endif %}
<select class="selectpicker show-tick" title="Category" data-width="170px" name="c">
<!--
On narrow viewports, there isn't enough room to fit the full stuff in the selectpicker, so we show a full-width one on wide viewports, but squish it on narrow ones.
-->
<select class="selectpicker show-tick visible-lg" title="Category" data-width="200px" name="c">
<option value="0_0" title="All categories" {% if search is defined and search["category"] == "0_0" %}selected{% else %}selected{% endif %}>
All categories
</option>
{% for cat_id, cat_name, cat_title in used_cats %}
<option value="{{ cat_id }}" title="{{ cat_title }}" {% if search is defined and search.category == cat_id %}selected{% endif %}>
{{ cat_name }}
</option>
{% endfor %}
</select>
<select class="selectpicker show-tick hidden-lg" title="Category" data-width="130px" name="c">
<option value="0_0" title="All categories" {% if search is defined and search["category"] == "0_0" %}selected{% else %}selected{% endif %}> <option value="0_0" title="All categories" {% if search is defined and search["category"] == "0_0" %}selected{% else %}selected{% endif %}>
All categories All categories
</option> </option>

View file

@ -30,51 +30,49 @@
{{ render_field(upload_form.category, class_='form-control')}} {{ render_field(upload_form.category, class_='form-control')}}
</div> </div>
</div> </div>
<div class="row"> <div class="row"></div>
</div>
<div class="row form-group"> <div class="row form-group">
<div class="col-md-6"> <div class="col-md-6">
{{ render_field(upload_form.information, class_='form-control', placeholder='Your website or IRC channel') }} {{ render_field(upload_form.information, class_='form-control', placeholder='Your website or IRC channel') }}
</div> </div>
<div class="col-md-6"> <div class="col-md-6">
<label class="control-label">Torrent flags</label><br> <label class="control-label">Torrent flags</label><br>
<div class="btn-group" data-toggle="buttons"> <div class="btn-group" data-toggle="buttons">
<label class="btn btn-default {% if not g.user %}active disabled{% endif %}" title="Upload torrent anonymously (don't display your username)"> <label class="btn btn-default {% if not g.user %}active disabled{% endif %}" title="Upload torrent anonymously (don't display your username)">
{{ upload_form.is_anonymous(disabled=(False if g.user else ""), checked=(False if g.user else "")) }} {{ upload_form.is_anonymous(disabled=(False if g.user else ""), checked=(False if g.user else "")) }}
{% if not g.user %}<span class="glyphicon glyphicon-asterisk"></span>{% endif %} {% if not g.user %}<span class="glyphicon glyphicon-asterisk"></span>{% endif %}
{% if g.user %}<span class="glyphicon glyphicon-ok"></span>{% endif %} {% if g.user %}<span class="glyphicon glyphicon-ok"></span>{% endif %}
{% if g.user %}<span class="glyphicon glyphicon-remove"></span>{% endif %} {% if g.user %}<span class="glyphicon glyphicon-remove"></span>{% endif %}
Anonymous Anonymous
</label> </label>
<label class="btn btn-grey" title="Hide torrent from listing"> <label class="btn btn-grey" title="Hide torrent from listing">
{{ upload_form.is_hidden }} {{ upload_form.is_hidden }}
<span class="glyphicon glyphicon-ok"></span> <span class="glyphicon glyphicon-ok"></span>
<span class="glyphicon glyphicon-remove"></span> <span class="glyphicon glyphicon-remove"></span>
Hidden Hidden
</label> </label>
<label class="btn btn-danger" title="This torrent is derived from another release"> <label class="btn btn-danger" title="This torrent is derived from another release">
{{ upload_form.is_remake }} {{ upload_form.is_remake }}
<span class="glyphicon glyphicon-ok"></span> <span class="glyphicon glyphicon-ok"></span>
<span class="glyphicon glyphicon-remove"></span> <span class="glyphicon glyphicon-remove"></span>
Remake Remake
</label> </label>
<label class="btn btn-warning" title="This torrent is a complete batch (eg. season)"> <label class="btn btn-warning" title="This torrent is a complete batch (eg. season)">
{{ upload_form.is_complete }} {{ upload_form.is_complete }}
<span class="glyphicon glyphicon-ok"></span> <span class="glyphicon glyphicon-ok"></span>
<span class="glyphicon glyphicon-remove"></span> <span class="glyphicon glyphicon-remove"></span>
Complete Complete
</label> </label>
{% if g.user.is_trusted %} {% if g.user.is_trusted %}
<label class="btn btn-success active" title="Mark torrent trusted"> <label class="btn btn-success active" title="Mark torrent trusted">
{{ upload_form.is_trusted(checked="") }} {{ upload_form.is_trusted(checked="") }}
<span class="glyphicon glyphicon-ok"></span> <span class="glyphicon glyphicon-ok"></span>
<span class="glyphicon glyphicon-remove"></span> <span class="glyphicon glyphicon-remove"></span>
Trusted Trusted
</label> </label>
{% endif %} {% endif %}
</div>
</div> </div>
</div> </div>
<div class="row"> <div class="row">
<div class="col-md-12"> <div class="col-md-12">