<% if (is_post()) { %>
<div class="uk-card uk-card-small uk-card-default uk-card-body mb-2">
    <div class="uk-card-title">文章目录</div>
    <div class="pt-1">
        <%- toc(page.content) %>
    </div>
</div>
<% } %>
<% if (!is_category() && !noCategories) { %>
<div class="uk-card uk-card-small uk-card-default uk-card-body mb-2">
    <div class="uk-card-title">知识分类</div>
    <div class="pt-1">
        <% if (site.categories.length == 0) { %>
        <div class="uk-alert-warning" uk-alert>
            <p>当前还没有分类。</p>
        </div>
        <% } else { %>
        <%- list_categories(site.categories, {
            class: 'category',
            style: 'list',
            show_count: false,
        }) %>
        <% } %>
    </div>
</div>
<% } %>
<% if (!is_tag() && !noTags) { %>
<div class="uk-card uk-card-small uk-card-default uk-card-body mb-2">
    <div class="uk-card-title">知识标签</div>
    <div class="pt-1">
        <% if (site.tags.length == 0) { %>
        <div class="uk-alert-warning" uk-alert>
            <p>当前还没有建立标签。</p>
        </div>
        <% } else { %>
        <%- partial('widget/tagcloud') %>
        <% } %>
    </div>
</div>
<% } %>
