chore: clean up extra space in documents
This commit is contained in:
parent
1bf0e7c3bb
commit
4330f60f32
25 changed files with 123 additions and 124 deletions
|
@ -1,22 +1,23 @@
|
|||
{% assign hidePagination = count or data.pages.size <= 1 %}
|
||||
{% assign media = data.items | default: data | normalizeMedia %}
|
||||
<div class="media-grid {% if shape == 'square' %}square{% else %}vertical{% endif %}">
|
||||
{% for item in media limit: count | default: media.size %}
|
||||
{% assign alt = item.alt | strip | escape %}
|
||||
{%- assign hidePagination = count or data.pages.size <= 1 -%}
|
||||
{%- assign media = data.items | default: data | normalizeMedia -%}
|
||||
<div class="media-grid {% if shape == 'square' -%}square{%- else -%}vertical{%- endif -%}">
|
||||
{%- for item in media limit: count | default: media.size -%}
|
||||
{%- capture alt -%}{{ item.title | escape }} ({{ item.year }}){% endcapture %}
|
||||
{%- assign alt = item.alt | strip | escape -%}
|
||||
<a href="{{ item.url }}" title="{{ alt }}">
|
||||
<div class="item-wrapper shadow">
|
||||
<div class="meta-text">
|
||||
{% if item.title %}
|
||||
{%- if item.title -%}
|
||||
<div class="header">{{ item.title }}</div>
|
||||
{% endif %}
|
||||
{% if item.plays %}
|
||||
{%- endif -%}
|
||||
{%- if item.plays -%}
|
||||
<div class="subheader">{{ item.plays }} plays</div>
|
||||
{% elsif item.subtext %}
|
||||
{%- elsif item.subtext -%}
|
||||
<div class="subheader">{{ item.subtext }}</div>
|
||||
{% endif %}
|
||||
{%- endif -%}
|
||||
</div>
|
||||
{% assign loadingStrategy = loading | default: 'lazy' %}
|
||||
{% if shape == 'square' %}
|
||||
{%- assign loadingStrategy = loading | default: 'lazy' -%}
|
||||
{%- if shape == 'square' -%}
|
||||
<img
|
||||
srcset="
|
||||
https://cdn.coryd.dev{{ item.image }}?class=squaresm 200w,
|
||||
|
@ -35,7 +36,7 @@
|
|||
width="240"
|
||||
height="240"
|
||||
/>
|
||||
{% else %}
|
||||
{%- else -%}
|
||||
<img
|
||||
srcset="
|
||||
https://cdn.coryd.dev{{ item.image }}?class=verticalsm 200w,
|
||||
|
@ -54,11 +55,11 @@
|
|||
width="200"
|
||||
height="307"
|
||||
/>
|
||||
{% endif %}
|
||||
{%- endif -%}
|
||||
</div>
|
||||
</a>
|
||||
{% endfor %}
|
||||
{%- endfor -%}
|
||||
</div>
|
||||
{% unless hidePagination %}
|
||||
{%- unless hidePagination -%}
|
||||
{% render "partials/nav/paginator.liquid", pagination:data %}
|
||||
{% endunless %}
|
||||
{%- endunless -%}
|
|
@ -1,7 +1,7 @@
|
|||
<div class="music-chart">
|
||||
{% assign items = data.items | default: data %}
|
||||
{%- assign items = data.items | default: data -%}
|
||||
<ol type="1">
|
||||
{% for item in items limit: count | default: items.size %}
|
||||
{%- for item in items limit: count | default: items.size -%}
|
||||
{%- assign playTotal = playTotal | default: mostPlayed -%}
|
||||
{%- assign percentage = item.plays | calculatePlayPercentage: playTotal -%}
|
||||
<li value="{{ item.rank }}">
|
||||
|
@ -11,13 +11,13 @@
|
|||
<div class="title">
|
||||
<a href="{{ item.url }}">{{ item.title }}</a>
|
||||
</div>
|
||||
{% capture playsLabel %}
|
||||
{% if item.plays > 1 %}
|
||||
{%- capture playsLabel -%}
|
||||
{%- if item.plays > 1 -%}
|
||||
plays
|
||||
{% else %}
|
||||
{%- else -%}
|
||||
play
|
||||
{% endif %}
|
||||
{% endcapture %}
|
||||
{%- endif -%}
|
||||
{%- endcapture -%}
|
||||
<div class="subtext">{{ item.artist }}</div>
|
||||
<div class="subtext">{{ item.plays }} {{ playsLabel }}</div>
|
||||
</div>
|
||||
|
@ -25,9 +25,9 @@
|
|||
{% render "partials/media/progress-bar.liquid", percentage:percentage %}
|
||||
</div>
|
||||
</li>
|
||||
{% endfor %}
|
||||
{%- endfor -%}
|
||||
</ol>
|
||||
</div>
|
||||
{% unless count %}
|
||||
{%- unless count -%}
|
||||
{% render "partials/nav/paginator.liquid", pagination:data %}
|
||||
{% endunless %}
|
||||
{%- endunless -%}
|
|
@ -1,6 +1,6 @@
|
|||
<div class="music-chart">
|
||||
{% for item in data limit: 10 %}
|
||||
{% capture alt %}{{ item.title | escape }} by {{ item.artist }}{% endcapture %}
|
||||
{%- for item in data limit: 10 -%}
|
||||
{%- capture alt -%}{{ item.title | escape }} by {{ item.artist }}{%- endcapture -%}
|
||||
<div class="item">
|
||||
<div class="meta">
|
||||
<img
|
||||
|
@ -28,5 +28,5 @@
|
|||
{{ item.timestamp | date: "%B %-d, %-I:%M%p", "America/Los_Angeles" }}
|
||||
</div>
|
||||
</div>
|
||||
{% endfor %}
|
||||
{%- endfor -%}
|
||||
</div>
|
|
@ -1,5 +1,5 @@
|
|||
{% if percentage %}
|
||||
{%- if percentage -%}
|
||||
<div class="progress-bar-wrapper" title="{{ percentage }}">
|
||||
<div style="width:{{ percentage }}" class="progress-bar"></div>
|
||||
</div>
|
||||
{% endif %}
|
||||
{%- endif -%}
|
|
@ -1,27 +1,25 @@
|
|||
{% assign hidePagination = count or data.pages.size <= 1 %}
|
||||
{%- assign hidePagination = count or data.pages.size <= 1 -%}
|
||||
<div class="watching grid{% if hidePagination %} no-pagination {% endif %}">
|
||||
{% assign items = data.items | default: mediaItems %}
|
||||
{% for item in items limit: count %}
|
||||
{% capture alt %}{{ item.title | escape }} ({{ item.year }}){% endcapture %}
|
||||
{%- assign items = data.items | default: mediaItems -%}
|
||||
{%- for item in items limit: count -%}
|
||||
{%- capture alt -%}{{ item.title | escape }} ({{ item.year }}){% endcapture %}
|
||||
<a href="{{ item.url }}">
|
||||
<div class="watching item shadow">
|
||||
<div class="meta-text">
|
||||
{% if item.type == 'movie' %}
|
||||
{%- if item.type == 'movie' -%}
|
||||
<div class="header">{{ item.title }}</div>
|
||||
<div class="subheader flex-centered">
|
||||
{{ item.year }}
|
||||
{% if item.rating %}
|
||||
{%- if item.rating -%}
|
||||
<span class="rating"> ({{ item.rating }})</span>
|
||||
{% endif %}
|
||||
{%- endif -%}
|
||||
</div>
|
||||
{% else %}
|
||||
{%- else -%}
|
||||
<div class="header">{{ item.name }}</div>
|
||||
<div class="subheader flex-centered">{{ item.year }}</div>
|
||||
{% endif %}
|
||||
{%- endif -%}
|
||||
</div>
|
||||
{%- capture loadingStrategy -%}
|
||||
{%- if loading -%}{{ loading }}{%- else -%}lazy{%- endif -%}
|
||||
{%- endcapture -%}
|
||||
{%- assign loadingStrategy = loading | default: 'lazy' -%}
|
||||
<img
|
||||
srcset="
|
||||
https://cdn.coryd.dev{{ item.backdrop }}?class=bannersm 256w,
|
||||
|
@ -42,8 +40,8 @@
|
|||
/>
|
||||
</div>
|
||||
</a>
|
||||
{% endfor %}
|
||||
{%- endfor -%}
|
||||
</div>
|
||||
{% unless hidePagination %}
|
||||
{%- unless hidePagination -%}
|
||||
{% render "partials/nav/paginator.liquid", pagination:data %}
|
||||
{% endunless %}
|
||||
{%- endunless -%}
|
|
@ -1,4 +1,4 @@
|
|||
{% capture alt %}{{ movie.title | escape }} ({{ movie.year }}){% endcapture %}
|
||||
{%- capture alt -%}{{ movie.title | escape }} ({{ movie.year }}){%- endcapture -%}
|
||||
<a href="{{ movie.url }}">
|
||||
<div class="watching hero shadow">
|
||||
<div class="meta-text">
|
||||
|
|
Reference in a new issue