forked from rDrama/rDrama
1
0
Fork 0
master
kek7198 2021-11-24 15:00:35 -06:00
parent 0ff71f454f
commit 6e686377be
1 changed files with 43 additions and 79 deletions

View File

@ -1,88 +1,52 @@
{% extends "default.html" %} {% extends "default.html" %}
{% block PseudoSubmitForm %}{% endblock %} {% block subHeader %}
{% block sortnav %}{% endblock %} <div class="relative max-w-screen-2xl mx-auto px-4 py-4 grid grid-cols-12 rounded-t-md">
<div class="absolute top-0 left-0 w-full h-full bg-gradient-to-t from-gray-800 to-gray-700 rounded-t-md sub-header-shadow"></div>
{% block content %} <div class="relative col-span-full flex items-center">
<div>
<pre></pre> <h1 class="font-bold text-xl font-heading leading-normal">
<div class="d-flex justify-content-between align-items-center"> Comments
</h1>
<div class="d-flex px-2 align-items-center sortingbarmargin"> <small class="block mt-1 text-gray-400">
<div class="text-small font-weight-bold mr-2"></div> <span class="capitalize font-bold">{{ sort }}</span>
<div class="dropdown dropdown-actions"> comments {{ 'from all time' if t=='all' else 'in the last' }}
<button class="btn btn-secondary dropdown-toggle" type="button" id="dropdownMenuButton" data-bs-toggle="dropdown" aria-haspopup="true" aria-expanded="false"> {% if t != 'all' %}<strong>{{ t }}</strong>{% endif %}
{% if t=="day" %}<i class="fas fa-calendar-day mr-1"></i>{% endif %} </small>
{% if t=="week" %}<i class="fas fa-calendar-week mr-1"></i>{% endif %}
{% if t=="month" %}<i class="fas fa-calendar-alt mr-1"></i>{% endif %}
{% if t=="year" %}<i class="fas fa-calendar mr-1"></i>{% endif %}
{% if t=="all" %}<i class="fas fa-infinity mr-1"></i>{% endif %}
{{t | capitalize}}
</button>
<div class="dropdown-menu" aria-labelledby="dropdownMenuButton" x-placement="bottom-start" style="position: absolute; will-change: transform; top: 0px; left: 0px; transform: translate3d(0px, 31px, 0px);">
{% if t !="hour" %}<a class="dropdown-item" href="?sort={{sort}}&t=hour"><i class="fas fa-clock mr-2"></i>Hour</a>{% endif %}
{% if t !="day" %}<a class="dropdown-item" href="?sort={{sort}}&t=day"><i class="fas fa-calendar-day mr-2"></i>Day</a>{% endif %}
{% if t !="week" %}<a class="dropdown-item" href="?sort={{sort}}&t=week"><i class="fas fa-calendar-week mr-2"></i>Week</a>{% endif %}
{% if t !="month" %}<a class="dropdown-item" href="?sort={{sort}}&t=month"><i class="fas fa-calendar-alt mr-2"></i>Month</a>{% endif %}
{% if t !="year" %}<a class="dropdown-item" href="?sort={{sort}}&t=year"><i class="fas fa-calendar mr-2"></i>Year</a>{% endif %}
{% if t !="all" %}<a class="dropdown-item" href="?sort={{sort}}&t=all"><i class="fas fa-infinity mr-2"></i>All</a>{% endif %}
</div>
</div> </div>
<div class="ml-auto">
<div class="text-small font-weight-bold ml-3 mr-2"></div> {% include "/dropdowns/SubmissionSorts.html" %}
<div class="dropdown dropdown-actions">
<button class="btn btn-secondary dropdown-toggle" type="button" id="dropdownMenuButton" data-bs-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
{% if sort=="top" %}<i class="fas fa-arrow-alt-circle-up mr-1"></i>{% endif %}
{% if sort=="bottom" %}<i class="fas fa-arrow-alt-circle-down mr-1"></i>{% endif %}
{% if sort=="new" %}<i class="fas fa-sparkles mr-1"></i>{% endif %}
{% if sort=="old" %}<i class="fas fa-book mr-1"></i>{% endif %}
{% if sort=="controversial" %}<i class="fas fa-bullhorn mr-1"></i>{% endif %}
{{sort | capitalize}}
</button>
<div class="dropdown-menu" aria-labelledby="dropdownMenuButton" x-placement="bottom-start" style="position: absolute; will-change: transform; top: 0px; left: 0px; transform: translate3d(0px, 31px, 0px);">
{% if sort != "top" %}<a class="dropdown-item" href="?sort=top&t={{t}}"><i class="fas fa-arrow-alt-circle-up mr-2"></i>Top</a>{% endif %}
{% if sort != "bottom" %}<a class="dropdown-item" href="?sort=bottom&t={{t}}"><i class="fas fa-arrow-alt-circle-down mr-2"></i>Bottom</a>{% endif %}
{% if sort != "new" %}<a class="dropdown-item" href="?sort=new&t={{t}}"><i class="fas fa-sparkles mr-2"></i>New</a>{% endif %}
{% if sort != "old" %}<a class="dropdown-item" href="?sort=old&t={{t}}"><i class="fas fa-book mr-2"></i>Old</a>{% endif %}
{% if sort != "controversial" %}<a class="dropdown-item" href="?sort=controversial&t={{t}}"><i class="fas fa-bullhorn mr-2"></i>Controversial</a>{% endif %}
</div>
</div> </div>
</div> </div>
</div> </div>
<div class="row no-gutters {% if listing %}mt-md-3{% elif not listing %}my-md-3{% endif %}">
<div class="col-12 px-3">
<div class="posts" id="posts">
{% include "comments.html" %}
</div>
</div>
</div>
{% endblock %} {% endblock %}
{% block pagenav %} {% block content %}
<nav aria-label="Page navigation"> <!-- Comments list -->
<ul class="pagination pagination-sm mb-0"> <div class="col-span-full">
{% if page>1 %} <div class="posts" id="posts">
<li class="page-item"> {% include "comments.html" %}
<small><a class="page-link" href="?page={{page-1}}&sort={{sort}}&t={{t}}" tabindex="-1">Prev</a></small> </div>
</li> </div>
{% else %} <!-- Pagination -->
<li class="page-item disabled"><span class="page-link">Prev</span></li> <div class="col-span-full">
{% endif %} <ul class="flex flex-wrap items-center mb-4">
{% if next_exists %} {% if page>1 %}
<li class="page-item"> <li>
<small><a class="page-link" href="?page={{page+1}}&sort={{sort}}&t={{t}}">Next</a></small> <a class="block px-2 py-1 text-sm font-bold text-pink-500 bg-gray-900" href="?page={{page-1}}&sort={{sort}}&t={{t}}" tabindex="-1">
</li> Prev
{% else %} </a>
<li class="page-item disabled"><span class="page-link">Next</span></li> </li>
{% endif %} {% else %}
</ul> <li><span class="block px-2 py-1 text-sm font-bold text-gray-700 bg-gray-800 disabled">Prev</span></li>
</nav> {% endif %}
{% if next_exists %}
<li class="page-item">
<a class="block px-2 py-1 text-sm font-bold text-pink-500 bg-gray-900" href="?page={{page+1}}&sort={{sort}}&t={{t}}">Next</a>
</li>
{% else %}
<li><span class="block px-2 py-1 text-sm font-bold text-gray-700 bg-gray-800 disabled">Next</span></li>
{% endif %}
</ul>
</div>
{% endblock %} {% endblock %}