Files
shop-pip/app/templates/index.html
T

116 lines
4.2 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
{% extends "base.html" %}
{% block content %}
<section class="hero">
<div class="hero-copy">
<p class="brand-mark">{{ app_name }}</p>
<h1>Цифровые товары без ожидания</h1>
<p class="hero-lead">
Ключи, софт и подарочные карты — оплатил и сразу получил код.
</p>
<div class="hero-actions">
<a class="btn btn-primary" href="#catalog">Смотреть каталог</a>
<a class="btn btn-ghost" href="/lookup">Найти заказ</a>
</div>
</div>
<div class="hero-visual" aria-hidden="true">
<div class="hero-plane"></div>
<div class="hero-orbit"></div>
</div>
</section>
<section class="categories" aria-label="Категории">
<div class="section-head">
<h2>Категории</h2>
<p>Выберите тип цифрового товара</p>
</div>
<ul class="category-list">
{% for category in categories %}
<li>
<a class="category-link" href="#catalog">
<span class="category-name">{{ category.name }}</span>
<span class="category-desc">{{ category.description }}</span>
</a>
</li>
{% endfor %}
</ul>
</section>
<section class="catalog" id="catalog">
<div class="section-head">
<h2>Каталог</h2>
<p>Популярные позиции с автоматической выдачей</p>
</div>
{% if featured %}
<div class="featured-rail" aria-label="Избранное">
{% for product in featured %}
<article class="product product-featured gradient-{{ product.image_gradient }} reveal">
<a class="product-media" href="/product/{{ product.slug }}"></a>
<div class="product-body">
<p class="product-tag">{{ product.delivery_note }}</p>
<h3><a href="/product/{{ product.slug }}">{{ product.title }}</a></h3>
<p>{{ product.short_description }}</p>
<div class="product-meta">
<span class="price">{{ product.price | rub }}</span>
<form method="post" action="/cart/add/{{ product.id }}">
<button type="submit" class="btn btn-small" {% if stock_map.get(product.id, 0) < 1 %}disabled{% endif %}>
{% if stock_map.get(product.id, 0) < 1 %}Нет в наличии{% else %}В корзину{% endif %}
</button>
</form>
</div>
</div>
</article>
{% endfor %}
</div>
{% endif %}
<div class="product-grid">
{% for product in products %}
<article class="product gradient-{{ product.image_gradient }} reveal">
<a class="product-media" href="/product/{{ product.slug }}"></a>
<div class="product-body">
<p class="product-tag">{{ product.delivery_note }}</p>
<h3><a href="/product/{{ product.slug }}">{{ product.title }}</a></h3>
<p>{{ product.short_description }}</p>
<div class="product-meta">
<span class="price">{{ product.price | rub }}</span>
<form method="post" action="/cart/add/{{ product.id }}">
<button type="submit" class="btn btn-small" {% if stock_map.get(product.id, 0) < 1 %}disabled{% endif %}>
{% if stock_map.get(product.id, 0) < 1 %}Нет в наличии{% else %}В корзину{% endif %}
</button>
</form>
</div>
</div>
</article>
{% else %}
<p class="empty">Товары скоро появятся.</p>
{% endfor %}
</div>
</section>
<section class="how" id="how">
<div class="section-head">
<h2>Как купить</h2>
<p>Три шага до цифрового кода</p>
</div>
<ol class="steps">
<li>
<span class="step-num">01</span>
<h3>Выберите товар</h3>
<p>Добавьте ключ, подписку или карту в корзину.</p>
</li>
<li>
<span class="step-num">02</span>
<h3>Оформите заказ</h3>
<p>Укажите email — туда привязывается выдача.</p>
</li>
<li>
<span class="step-num">03</span>
<h3>Получите сразу</h3>
<p>Коды открываются на странице заказа мгновенно.</p>
</li>
</ol>
</section>
{% endblock %}