simpler streamer

This commit is contained in:
sakrecoer 2020-07-05 19:39:50 +02:00
parent 27802de9b7
commit 6d7eedd8c4

View file

@ -1,33 +1,13 @@
{% if page.collection == 'tracks' %} <section class="streambox" style="margin-top:40px;padding: 40px;">
<section class="streambox" style="margin-top:40px;"> {% if page.collection == 'posts' %}
<h3 style="text-align: center;display: block;">Buy pax:nion Music</h3>
<div class="streamer">
{% for shop in site.data.stores %}
{% if shop.download == true %}
<a onclick="_paq.push(['trackEvent', 'StoreLink', '{{ shop.name | remove: " " }}']);" target="_blank" rel="noopener" href="{{ shop.url }}" alt="Stream from {{ shop.name }}" title="Stream from {{ shop.name }}" class="button icon brands {{ shop.icon }}">Buy on {{ shop.name }}</a>
{% endif %}
{% endfor %}
</div>
<h3 style="text-align: center;display: block;margin-top:40px;">Stream</h3> {% if page.stores[0].name != nil %}
<div class="streamer">
{% for shop in site.data.stores %}
{% if shop.download != true %}
<a onclick="_paq.push(['trackEvent', 'StoreLink', '{{ shop.name | remove: " " }}']);" style="flex: 0 0 75px;margin:10px; font-size: 75px;" target="_blank" rel="noopener" href="{{ shop.url }}" alt="Stream from {{ shop.name }}" title="Stream from {{ shop.name }}" class="icon style2 brands {{ shop.icon }}"><span class="label">{{ shop.name }}</span></a>
{% endif %}
{% endfor %}
</div>
</section>
{% else %}
{% if page.stores[0].name != nil %}
<section class="streambox" style="margin-top:40px;">
<h3 style="text-align: center;display: block;">Buy this record</h3> <h3 style="text-align: center;display: block;">Buy this record</h3>
<div class="streamer"> <div class="streamer">
{% for shop in page.stores %} {% for shop in page.stores %}
{% if shop.download == true %} {% if shop.download == true %}
<a onclick="_paq.push(['trackEvent', 'StoreLink', '{{ shop.name | remove: " " }}']);" target="_blank" rel="noopener" href="{{ shop.url }}" alt="Stream from {{ shop.name }}" title="Stream from {{ shop.name }}" class="button icon brands {{ shop.icon }}">Buy on {{ shop.name }}</a> <a onclick="_paq.push(['trackEvent', 'StoreLink', '{{ shop.name | remove: " " }}']);" target="_blank" rel="noopener" href="{{ shop.url }}" alt="Stream from {{ shop.name }}" title="Stream from {{ shop.name }}" class="button icon brands {{ shop.icon }}">{{ shop.name }}</a>
{% endif %} {% endif %}
{% endfor %} {% endfor %}
</div> </div>
@ -42,9 +22,11 @@
{% endif %} {% endif %}
{% endfor %} {% endfor %}
</div> </div>
</section>
{% else %} {% endif %}
<section class="streambox" style="margin-top:40px;">
{% elsif page.collection == 'tracks' or page.collection == 'albums' %}
{% if page.collection == 'albums' %} {% if page.collection == 'albums' %}
<h3 style="text-align: center;display: block;">This release&nbsp; can't be bought</h3> <h3 style="text-align: center;display: block;">This release&nbsp; can't be bought</h3>
<p>But other releases are available here:</p> <p>But other releases are available here:</p>
@ -56,10 +38,11 @@
<div class="streamer"> <div class="streamer">
{% for shop in site.data.stores %} {% for shop in site.data.stores %}
{% if shop.download == true %} {% if shop.download == true %}
<a onclick="_paq.push(['trackEvent', 'StoreLink', '{{ shop.name | remove: " " }}']);" target="_blank" rel="noopener" href="{{ shop.url }}" alt="Stream from {{ shop.name }}" title="Stream from {{ shop.name }}" class="button icon brands {{ shop.icon }}">Buy on {{ shop.name }}</a> <a onclick="_paq.push(['trackEvent', 'StoreLink', '{{ shop.name | remove: " " }}']);" target="_blank" rel="noopener" href="{{ shop.url }}" alt="Stream from {{ shop.name }}" title="Stream from {{ shop.name }}" class="button icon brands {{ shop.icon }}">{{ shop.name }}</a>
{% endif %} {% endif %}
{% endfor %} {% endfor %}
</div> </div>
</section>
{% endif %}
{% endif %} {% endif %}
</section>