{% extends "root.html" %}
{% from "_macros.html" import rank_badge, cuisine_links, hours_badge %}
{% block content %}
<div class="space-y-4">
<a href="/cuisines{% if area %}?area={{ area.id }}{% endif %}" class="btn btn-ghost btn-sm">← Cuisines</a>
<div class="flex items-end justify-between gap-3 flex-wrap">
<h2 class="text-2xl font-bold text-accent capitalize">{{ cuisine }}</h2>
<p class="text-sm opacity-70">
{{ total }} place{{ "" if total == 1 else "s" }}{% if area %} in {{ area.name }} ·
<a class="link" href="/cuisines/{{ cuisine | urlencode }}">every area</a>{% endif %}
</p>
</div>
{% if total == 0 %}
<p class="text-sm opacity-70">Nothing tagged {{ cuisine }}{% if area %} in {{ area.name }}{% endif %}.</p>
{% endif %}
{% for g in groups %}
<section class="space-y-2">
{% if not area %}<h3 class="font-semibold"><a class="link link-hover" href="/areas/{{ g.area_id }}">{{ g.area_name }}</a></h3>{% endif %}
<div class="overflow-x-auto border border-base-300 rounded-box">
<table class="table table-sm">
<thead><tr><th>Restaurant</th><th>Your rank</th><th>Today</th><th class="text-right">Visits</th><th>Last</th></tr></thead>
<tbody>
{% for r in g.rows %}
<tr>
<td>
<a href="/restaurants/{{ r.restaurant.id }}" class="font-semibold link link-hover">{{ r.restaurant.name }}</a>
<span class="block text-xs opacity-70">{{ cuisine_links(r.cuisines, area.id if area else none) }}</span>
</td>
<td>{{ rank_badge(r.my_rank) }}</td>
<td>{{ hours_badge(r.lunch_today) }}</td>
<td class="text-right font-mono">{{ r.visits }}</td>
<td class="font-mono text-xs whitespace-nowrap">{{ r.last_visit or "—" }}</td>
</tr>
{% endfor %}
</tbody>
</table>
</div>
</section>
{% endfor %}
</div>
{% endblock %}
neiam
/fieri-forever
the flavortown lunch engine
public · Issues · Pulls · Labels · Forks · Compare · Actions success · Badges · Packages
⭐
Log in to mark this repository.
1.9 KiB · text
History
7a00c02