1
0
Fork 0
miniflux/template/templates/views/categories.html

60 lines
2.7 KiB
HTML
Raw Normal View History

{{ define "title"}}{{ t "page.categories.title" }} ({{ .total }}){{ end }}
2017-11-20 00:10:04 -05:00
{{ define "content"}}
<section class="page-header">
<h1>{{ t "page.categories.title" }} ({{ .total }})</h1>
2017-11-20 00:10:04 -05:00
<ul>
<li>
<a href="{{ route "createCategory" }}">{{ t "menu.create_category" }}</a>
2017-11-20 00:10:04 -05:00
</li>
</ul>
</section>
{{ if not .categories }}
<p class="alert alert-error">{{ t "alert.no_category" }}</p>
2017-11-20 00:10:04 -05:00
{{ else }}
<div class="items">
{{ range .categories }}
<article class="item">
2020-06-25 00:46:37 -04:00
<div class="item-header" dir="auto">
2017-11-20 00:10:04 -05:00
<span class="item-title">
<a href="{{ route "categoryEntries" "categoryID" .ID }}">{{ .Title }}</a>
</span>
2019-11-17 22:44:12 -05:00
(<span title="{{ if eq .FeedCount 0 }}{{ t "page.categories.no_feed" }}{{ else }}{{ plural "page.categories.feed_count" .FeedCount .FeedCount }}{{ end }}">{{ .FeedCount }}</span>)
2017-11-20 00:10:04 -05:00
</div>
<div class="item-meta">
2020-03-22 19:33:35 -04:00
<ul class="item-meta-info">
2017-11-20 00:10:04 -05:00
<li>
2020-06-14 22:00:41 -04:00
{{ if eq .FeedCount 0 }}{{ t "page.categories.no_feed" }}{{ else }}{{ plural "page.categories.feed_count" .FeedCount .FeedCount }}{{ end }}
</li>
</ul>
<ul class="item-meta-icons">
<li>
<a href="{{ route "categoryEntries" "categoryID" .ID }}">{{ template "icon_entries" }}<span class="icon-label">{{ t "page.categories.entries" }}</span></a>
</li>
<li>
<a href="{{ route "categoryFeeds" "categoryID" .ID }}">{{ template "icon_feeds" }}<span class="icon-label">{{ t "page.categories.feeds" }}</span></a>
2017-11-20 00:10:04 -05:00
</li>
<li>
2020-06-14 22:00:41 -04:00
<a href="{{ route "editCategory" "categoryID" .ID }}">{{ template "icon_edit" }}<span class="icon-label">{{ t "menu.edit_category" }}</span></a>
2017-11-20 00:10:04 -05:00
</li>
{{ if eq .FeedCount 0 }}
<li>
<a href="#"
data-confirm="true"
data-label-question="{{ t "confirm.question" }}"
data-label-yes="{{ t "confirm.yes" }}"
data-label-no="{{ t "confirm.no" }}"
data-label-loading="{{ t "confirm.loading" }}"
2020-06-14 22:00:41 -04:00
data-url="{{ route "removeCategory" "categoryID" .ID }}">{{ template "icon_delete" }}<span class="icon-label">{{ t "action.remove" }}</span></a>
2017-11-20 00:10:04 -05:00
</li>
{{ end }}
</ul>
</div>
</article>
{{ end }}
</div>
{{ end }}
{{ end }}