diff --git a/_collections/_merch/plushies.md b/_collections/_merch/plushies.md index 076f556f..e48e2ba6 100644 --- a/_collections/_merch/plushies.md +++ b/_collections/_merch/plushies.md @@ -2,12 +2,24 @@ layout: merch title: TeX Plushies slug: plushies -purchase-url: https://www.guildofstudents.com/shop/product/10317460/ -options: - - name: Plushie - quantity: 1 - price: 13.99 - note: Limited to members only +purchase-options: + - url: https://www.guildofstudents.com/shop/product/10317460/ + type: guild + text: Buy on Guild website + icon: fa-arrow-up-right-from-square + options: + - name: Plushie + quantity: 1 + price: 13.99 + note: Limited to members only + - url: /assets/tex-pattern.pdf + type: download + text: Download + icon: fa-download + options: + - name: Pattern + price: 0 + note: For if you want to make one yourself! gallery: - url: /assets/images/tex-plushie/20250426_0008_lowres.jpg alt: TeX reading a book diff --git a/_layouts/merch.html b/_layouts/merch.html index 3ebca606..44b7a513 100644 --- a/_layouts/merch.html +++ b/_layouts/merch.html @@ -32,7 +32,8 @@

Gallery

{% endif %}

Purchase options

- {% for option in page.options %} + {% for group in page.purchase-options %} + {% for option in group.options %}
{% if option.quantity %}
@@ -45,14 +46,19 @@

Purchase options

{{ option.note }} {% endif %}
- £{{ option.price }} + {% if option.price > 0 %} + £{{ option.price }} + {% else %} + Free + {% endif %}
+ {% endfor %} + {% if group.url %} + {{ group.text }} + {% else %} + Currently unavailable + {% endif %} {% endfor %} - {% if page.purchase-url %} - Buy on Guild website - {% else %} - Currently unavailable - {% endif %}
diff --git a/assets/tex-pattern.pdf b/assets/tex-pattern.pdf new file mode 100644 index 00000000..46c810fc Binary files /dev/null and b/assets/tex-pattern.pdf differ diff --git a/css/merch.scss b/css/merch.scss index adfd2f05..69a29774 100644 --- a/css/merch.scss +++ b/css/merch.scss @@ -144,6 +144,15 @@ background-color: #5bbaa2; } +.download-button { + background-color: lightgray; + color: black; + + i { + color: black; + } +} + .unavailable-button { background-color: gray; cursor: not-allowed; @@ -180,7 +189,7 @@ .purchase { width: 100%; - top: -60px; + position: static; } .merch-description { diff --git a/merch.html b/merch.html index 994dd79a..ca2f82dc 100644 --- a/merch.html +++ b/merch.html @@ -25,10 +25,11 @@

{{ merch.title }}

{{ merch.excerpt | strip_html }}

- {% if merch.options %} + + {% endfor %}