Files
slump-x-land-studio/templates/shop/index.html
T

41 lines
1.9 KiB
HTML

{% extends 'base.html' %}
{% block title %}Shop · SLUMP X LAND{% endblock %}
{% block content %}
<main class="page-shell theme-shop">
<header class="section-head" style="display:flex;justify-content:space-between;align-items:center;gap:1rem;">
<h1>Shop</h1>
<a class="btn" href="{% url 'shop-cart' %}">Cart ({{ cart_count }})</a>
</header>
{% if request.GET.subscribed %}
<p class="notice">Thank you! Your subscription is processing and will activate momentarily.</p>
{% endif %}
<div class="shop-grid">
{% for product in products %}
<article class="card shop-product">
<a href="{% url 'shop-product' product.slug %}" style="text-decoration:none;color:inherit;display:block;padding:1rem 1rem 0;">
<div class="shop-image{% if product.image %} has-shop-image{% endif %}" data-shop-image>
{% if product.image %}
<img src="{{ product.image.url }}" alt="{{ product.title }}" onerror="this.style.display='none';this.parentElement.classList.remove('has-shop-image');">
{% endif %}
<div class="shop-image-placeholder">SLX</div>
</div>
</a>
<header>
<span class="badge">{{ product.get_kind_display }}</span>
<h2 style="margin-top:.4rem;"><a href="{% url 'shop-product' product.slug %}">{{ product.title }}</a></h2>
{% if product.summary %}<p>{{ product.summary }}</p>{% endif %}
</header>
<div class="shop-option" style="display:flex;justify-content:space-between;align-items:center;gap:.75rem;">
<strong>${{ product.price_usd }}{% if product.kind == 'subscription' %} / {{ product.billing_interval }}{% endif %}</strong>
<a class="btn" href="{% url 'shop-product' product.slug %}">View Details</a>
</div>
</article>
{% empty %}
<p>No shop items are live yet. Check back soon.</p>
{% endfor %}
</div>
</main>
{% endblock %}