mirror of
https://github.com/next-theme/hexo-theme-next.git
synced 2026-01-18 18:33:42 +00:00
parent
f677a588b2
commit
07097c8537
7
.github/workflows/linter.yml
vendored
7
.github/workflows/linter.yml
vendored
@ -20,3 +20,10 @@ jobs:
|
||||
uses: coverallsapp/github-action@master
|
||||
with:
|
||||
github-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
- name: Set up Python
|
||||
uses: actions/setup-python@v2
|
||||
- name: Install Dependencies
|
||||
run: |
|
||||
python -m pip install --upgrade pip
|
||||
pip install curlylint
|
||||
- run: curlylint --include .njk layout
|
||||
|
||||
@ -39,7 +39,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
{%- if theme.back2top.enable and theme.back2top.sidebar %}
|
||||
<div class="back-to-top animated" role="button" aria-label="{{ __('accessibility.back_to_top') }}">
|
||||
<i class="fa fa-arrow-up"></i>
|
||||
|
||||
@ -83,11 +83,11 @@
|
||||
|
||||
{{- next_inject('postMeta') }}
|
||||
|
||||
{%- if theme.symbols_count_time.separated_meta and config.symbols_count_time.symbols and config.symbols_count_time.time %}
|
||||
<span class="post-meta-break"></span>
|
||||
{%- endif %}
|
||||
|
||||
{%- if config.symbols_count_time.symbols %}
|
||||
{%- if theme.symbols_count_time.separated_meta %}
|
||||
</div>
|
||||
<div class="post-meta">
|
||||
{%- endif %}
|
||||
<span class="post-meta-item" title="{{ __('symbols_count_time.count') }}">
|
||||
<span class="post-meta-item-icon">
|
||||
<i class="far fa-file-word"></i>
|
||||
|
||||
@ -12,11 +12,8 @@
|
||||
<nav class="site-state">
|
||||
{%- if config.archive_dir != '/' and site.posts.length > 0 %}
|
||||
<div class="site-state-item site-state-posts">
|
||||
{%- if theme.menu.archives %}
|
||||
<a href="{{ url_for(theme.menu.archives.split('||')[0] | trim) }}">
|
||||
{% else %}
|
||||
<a href="{{ url_for(config.archive_dir) }}">
|
||||
{%- endif %}
|
||||
{%- set archive_dir = theme.menu.archives.split('||')[0] | trim if theme.menu.archives else config.archive_dir + '/' %}
|
||||
<a href="{{ url_for(archive_dir) }}">
|
||||
<span class="site-state-item-count">{{ site.posts.length }}</span>
|
||||
<span class="site-state-item-name">{{ __('state.posts') }}</span>
|
||||
</a>
|
||||
@ -27,12 +24,9 @@
|
||||
{%- set categoriesPageQuery = site.pages.find({type: 'categories'}, {lean: true}) %}
|
||||
{%- set hasCategoriesPage = categoriesPageQuery.length > 0 %}
|
||||
<div class="site-state-item site-state-categories">
|
||||
{%- set category_dir = theme.menu.categories.split('||')[0] | trim if theme.menu.categories else config.category_dir + '/' %}
|
||||
{%- if hasCategoriesPage %}
|
||||
{%- if theme.menu.categories %}
|
||||
<a href="{{ url_for(theme.menu.categories.split('||')[0] | trim) }}">
|
||||
{% else %}
|
||||
<a href="{{ url_for(config.category_dir) + '/' }}">
|
||||
{%- endif %}
|
||||
<a href="{{ url_for(category_dir) }}">
|
||||
{%- endif %}
|
||||
<span class="site-state-item-count">{{ site.categories.length }}</span>
|
||||
<span class="site-state-item-name">{{ __('state.categories') }}</span>
|
||||
@ -44,12 +38,9 @@
|
||||
{%- set tagsPageQuery = site.pages.find({type: 'tags'}, {lean: true}) %}
|
||||
{%- set hasTagsPage = tagsPageQuery.length > 0 %}
|
||||
<div class="site-state-item site-state-tags">
|
||||
{%- set tag_dir = theme.menu.tags.split('||')[0] | trim if theme.menu.tags else config.tag_dir + '/' %}
|
||||
{%- if hasTagsPage %}
|
||||
{%- if theme.menu.tags %}
|
||||
<a href="{{ url_for(theme.menu.tags.split('||')[0] | trim) }}">
|
||||
{% else %}
|
||||
<a href="{{ url_for(config.tag_dir) + '/' }}">
|
||||
{%- endif %}
|
||||
<a href="{{ url_for(tag_dir) }}">
|
||||
{%- endif %}
|
||||
<span class="site-state-item-count">{{ site.tags.length }}</span>
|
||||
<span class="site-state-item-name">{{ __('state.tags') }}</span>
|
||||
@ -62,14 +53,10 @@
|
||||
|
||||
{%- if theme.chat.enable and (theme.chatra.enable or theme.tidio.enable or theme.gitter.enable) %}
|
||||
<div class="sidebar-button site-overview-item animated">
|
||||
{%- if theme.chatra.enable or theme.tidio.enable %}
|
||||
<button>
|
||||
{%- elif theme.gitter.enable %}
|
||||
<button class="js-gitter-toggle-chat-button">
|
||||
{%- endif %}
|
||||
{%- if theme.chat.icon %}<i class="{{ theme.chat.icon }}"></i>{%- endif %}
|
||||
{{ theme.chat.text }}
|
||||
</button>
|
||||
<button{% if theme.gitter.enable %} class="js-gitter-toggle-chat-button"{% endif %}>
|
||||
{%- if theme.chat.icon %}<i class="{{ theme.chat.icon }}"></i>{%- endif %}
|
||||
{{ theme.chat.text }}
|
||||
</button>
|
||||
</div>
|
||||
{%- endif %}
|
||||
|
||||
|
||||
@ -91,7 +91,7 @@
|
||||
}
|
||||
|
||||
// .post-meta-item exists in .post-meta and footer
|
||||
.post-meta-item:not(:first-child)::before {
|
||||
:not(.post-meta-break) + .post-meta-item::before {
|
||||
content: '|';
|
||||
margin: 0 .5em;
|
||||
}
|
||||
@ -110,6 +110,11 @@
|
||||
}
|
||||
}
|
||||
|
||||
.post-meta-break {
|
||||
flex-basis: 100%;
|
||||
height: 0;
|
||||
}
|
||||
|
||||
if (hexo-config('busuanzi_count.enable') and hexo-config('busuanzi_count.post_views')) {
|
||||
#busuanzi_container_page_pv {
|
||||
display: none;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user