mirror of
https://github.com/pmoreno-rodriguez/grav-theme-future2021.git
synced 2025-06-07 20:08:54 +00:00
Autoformatted some twigs
This commit is contained in:
parent
ecc1d5c964
commit
497b24e594
6 changed files with 76 additions and 74 deletions
|
@ -1,11 +1,13 @@
|
||||||
<ul class="related-pages">
|
<ul class="related-pages">
|
||||||
{% for related_path, score in related_pages %}
|
{% for related_path, score in related_pages %}
|
||||||
{% set related = grav['pages'].get(related_path) %}
|
{% set related = grav['pages'].get(related_path) %}
|
||||||
{% if related %}
|
{% if related %}
|
||||||
<li>
|
<li>
|
||||||
<a href="{{ related.url }}" title="{{ related.title }}">{{ related.title }}</a> {% if config.plugins.relatedpages.show_score %}<span class="score">( {{ score }} )</span>
|
<a href="{{ related.url }}" title="{{ related.title }}">{{ related.title }}</a>
|
||||||
{% endif %}
|
{% if config.plugins.relatedpages.show_score %}
|
||||||
</li>
|
<span class="score">( {{ score }} )</span>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% endfor %}
|
</li>
|
||||||
</ul>
|
{% endif %}
|
||||||
|
{% endfor %}
|
||||||
|
</ul>
|
||||||
|
|
|
@ -1,25 +1,25 @@
|
||||||
{% set min_chars = config.get('plugins.simplesearch.min_query_length', 3) %}
|
{% set min_chars = config.get('plugins.simplesearch.min_query_length', 3) %}
|
||||||
|
|
||||||
<li class="search">
|
<li class="search">
|
||||||
<a class="fa-search" href="#search">{{"PLUGIN_SIMPLESEARCH.SEARCH_PLACEHOLDER"|t}}</a>
|
<a class="fa-search" href="#search">{{"PLUGIN_SIMPLESEARCH.SEARCH_PLACEHOLDER"|t}}</a>
|
||||||
<form id="search" data-simplesearch-form>
|
<form id="search" data-simplesearch-form>
|
||||||
<input
|
<input
|
||||||
name="searchfield"
|
name="searchfield"
|
||||||
class="search-input"
|
class="search-input"
|
||||||
aria-label="search"
|
aria-label="search"
|
||||||
type="text"
|
type="text"
|
||||||
{% if min_chars > 0 %} data-min="{{- min_chars -}}" {% endif %}
|
{% if min_chars > 0 %} data-min="{{- min_chars -}}" {% endif %}
|
||||||
required
|
required
|
||||||
placeholder="{{"PLUGIN_SIMPLESEARCH.SEARCH_PLACEHOLDER"|t}}"
|
placeholder="{{"PLUGIN_SIMPLESEARCH.SEARCH_PLACEHOLDER"|t}}"
|
||||||
value="{{ query|e }}"
|
value="{{ query|e }}"
|
||||||
data-search-invalid="{{ "PLUGIN_SIMPLESEARCH.SEARCH_FIELD_MINIMUM_CHARACTERS"|t(min_chars)|raw }}"
|
data-search-invalid="{{ "PLUGIN_SIMPLESEARCH.SEARCH_FIELD_MINIMUM_CHARACTERS"|t(min_chars)|raw }}"
|
||||||
data-search-separator="{{ config.system.param_sep }}"
|
data-search-separator="{{ config.system.param_sep }}"
|
||||||
data-search-input="{{ base_url_absolute }}{{ config.plugins.simplesearch.route == '@self' ? '' : (config.plugins.simplesearch.route == '/' ? '' : config.plugins.simplesearch.route) }}/query"
|
data-search-input="{{ base_url_absolute }}{{ config.plugins.simplesearch.route == '@self' ? '' : (config.plugins.simplesearch.route == '/' ? '' : config.plugins.simplesearch.route) }}/query"
|
||||||
/>
|
/>
|
||||||
{% if config.plugins.simplesearch.display_button %}
|
{% if config.plugins.simplesearch.display_button %}
|
||||||
<button type="submit" class="search-submit">
|
<button type="submit" class="search-submit">
|
||||||
<img src="{{ url('plugin://simplesearch/assets/search.svg') }}" />
|
<img src="{{ url('plugin://simplesearch/assets/search.svg') }}" />
|
||||||
</button>
|
</button>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
</form>
|
</form>
|
||||||
</li>
|
</li>
|
|
@ -1,24 +1,24 @@
|
||||||
{% set min_chars = config.get('plugins.simplesearch.min_query_length', 3) %}
|
{% set min_chars = config.get('plugins.simplesearch.min_query_length', 3) %}
|
||||||
|
|
||||||
<div class="search-wrapper">
|
<div class="search-wrapper">
|
||||||
<form name="search" data-simplesearch-form>
|
<form name="search" data-simplesearch-form>
|
||||||
<input
|
<input
|
||||||
name="searchfield"
|
name="searchfield"
|
||||||
class="search-input"
|
class="search-input"
|
||||||
aria-label="search"
|
aria-label="search"
|
||||||
type="text"
|
type="text"
|
||||||
{% if min_chars > 0 %} data-min="{{- min_chars -}}" {% endif %}
|
{% if min_chars > 0 %} data-min="{{- min_chars -}}" {% endif %}
|
||||||
required
|
required
|
||||||
placeholder="{{"PLUGIN_SIMPLESEARCH.SEARCH_PLACEHOLDER"|t}}"
|
placeholder="{{"PLUGIN_SIMPLESEARCH.SEARCH_PLACEHOLDER"|t}}"
|
||||||
value="{{ query|e }}"
|
value="{{ query|e }}"
|
||||||
data-search-invalid="{{ "PLUGIN_SIMPLESEARCH.SEARCH_FIELD_MINIMUM_CHARACTERS"|t(min_chars)|raw }}"
|
data-search-invalid="{{ "PLUGIN_SIMPLESEARCH.SEARCH_FIELD_MINIMUM_CHARACTERS"|t(min_chars)|raw }}"
|
||||||
data-search-separator="{{ config.system.param_sep }}"
|
data-search-separator="{{ config.system.param_sep }}"
|
||||||
data-search-input="{{ base_url }}{{ config.plugins.simplesearch.route == '@self' ? '' : (config.plugins.simplesearch.route == '/' ? '' : config.plugins.simplesearch.route) }}/query"
|
data-search-input="{{ base_url }}{{ config.plugins.simplesearch.route == '@self' ? '' : (config.plugins.simplesearch.route == '/' ? '' : config.plugins.simplesearch.route) }}/query"
|
||||||
/>
|
/>
|
||||||
{% if config.plugins.simplesearch.display_button %}
|
{% if config.plugins.simplesearch.display_button %}
|
||||||
<button type="submit" class="search-submit">
|
<button type="submit" class="search-submit">
|
||||||
<img src="{{ url('plugin://simplesearch/assets/search.svg') }}" />
|
<img src="{{ url('plugin://simplesearch/assets/search.svg') }}" />
|
||||||
</button>
|
</button>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -1,22 +1,22 @@
|
||||||
{% set min_chars = config.get('plugins.simplesearch.min_query_length', 3) %}
|
{% set min_chars = config.get('plugins.simplesearch.min_query_length', 3) %}
|
||||||
|
|
||||||
<form class="search" data-simplesearch-form>
|
<form class="search" data-simplesearch-form>
|
||||||
<input
|
<input
|
||||||
name="searchfield"
|
name="searchfield"
|
||||||
class="search-input"
|
class="search-input"
|
||||||
aria-label="search"
|
aria-label="search"
|
||||||
type="text"
|
type="text"
|
||||||
{% if min_chars > 0 %} data-min="{{- min_chars -}}" {% endif %}
|
{% if min_chars > 0 %} data-min="{{- min_chars -}}" {% endif %}
|
||||||
required
|
required
|
||||||
placeholder="{{"PLUGIN_SIMPLESEARCH.SEARCH_PLACEHOLDER"|t}}"
|
placeholder="{{"PLUGIN_SIMPLESEARCH.SEARCH_PLACEHOLDER"|t}}"
|
||||||
value="{{ query|e }}"
|
value="{{ query|e }}"
|
||||||
data-search-invalid="{{ "PLUGIN_SIMPLESEARCH.SEARCH_FIELD_MINIMUM_CHARACTERS"|t(min_chars)|raw }}"
|
data-search-invalid="{{ "PLUGIN_SIMPLESEARCH.SEARCH_FIELD_MINIMUM_CHARACTERS"|t(min_chars)|raw }}"
|
||||||
data-search-separator="{{ config.system.param_sep }}"
|
data-search-separator="{{ config.system.param_sep }}"
|
||||||
data-search-input="{{ base_url_absolute }}{{ config.plugins.simplesearch.route == '@self' ? '' : (config.plugins.simplesearch.route == '/' ? '' : config.plugins.simplesearch.route) }}/query"
|
data-search-input="{{ base_url_absolute }}{{ config.plugins.simplesearch.route == '@self' ? '' : (config.plugins.simplesearch.route == '/' ? '' : config.plugins.simplesearch.route) }}/query"
|
||||||
/>
|
/>
|
||||||
{% if config.plugins.simplesearch.display_button %}
|
{% if config.plugins.simplesearch.display_button %}
|
||||||
<button type="submit" class="search-submit">
|
<button type="submit" class="search-submit">
|
||||||
<img src="{{ url('plugin://simplesearch/assets/search.svg') }}" />
|
<img src="{{ url('plugin://simplesearch/assets/search.svg') }}" />
|
||||||
</button>
|
</button>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
</form>
|
</form>
|
||||||
|
|
|
@ -1,3 +1,3 @@
|
||||||
{% for item in theme_config.social %}
|
{% for item in theme_config.social %}
|
||||||
<li><a href="{{ item.url }}" class="icon brands {{item.icon}}"><span class="label">{{item.name}}</span></a></li>
|
<li><a href="{{ item.url }}" class="icon brands {{item.icon}}"><span class="label">{{item.name}}</span></a></li>
|
||||||
{% endfor %}
|
{% endfor %}
|
|
@ -3,10 +3,10 @@
|
||||||
{% if taxlist %}
|
{% if taxlist %}
|
||||||
<ul class="menulink">
|
<ul class="menulink">
|
||||||
<li>
|
<li>
|
||||||
{% for tax,value in taxlist[taxonomy]|sort %}
|
{% for tax,value in taxlist[taxonomy]|sort %}
|
||||||
{% set active = uri.param(taxonomy) == tax? 'active' : '' %}
|
{% set active = uri.param(taxonomy) == tax? 'active' : '' %}
|
||||||
<a class="tags {{ active }}" href="{{ base_url }}/{{ taxonomy }}{{ config.system.param_sep }}{{ tax }}">{{ tax }}</a>
|
<a class="tags {{ active }}" href="{{ base_url }}/{{ taxonomy }}{{ config.system.param_sep }}{{ tax }}">{{ tax }}</a>
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
Loading…
Add table
Reference in a new issue