Ejemplo generado por CULTIVA IA · Skill: shopify-desarrollo-tiendas · Cliente: Botánica Viva
🌱 Colección Primavera 2026

Tu hogar,
más verde
que nunca

Plantas seleccionadas a mano, con cariño, enviadas a toda España.

Ver toda la tienda Saber más

Plantas Destacadas

Selección de la semana — editada desde el panel de Shopify sin código

🌿 Más vendido
Monstera Deliciosa
Planta tropical de interior
29,95 € 35,00 €
🌵 Pack
Pack Suculentas Mix
6 suculentas variadas
18,50 €
🏺 Artesanal
Maceta Barro Artesanal
Hecha a mano en Madrid
14,00 €
🍃
Pothos Áureo
Planta colgante de interior
12,95 €
🌵
Cactus Decorativo
Maceta cerámica incluida
9,95 €

⚙️ Sección editable desde el admin de Shopify — {% schema %}

text Título de la sección "Plantas Destacadas"
collection Colección a mostrar plantas-destacadas
range (2–12) Número de productos 5
checkbox Mostrar badges de descuento true

¿Por qué Botánica Viva?

Cada bloque es editable desde el panel de administración

🚚
Envío en 24–48h
Enviamos con packaging especial para que tu planta llegue perfecta a casa.
🌱
Garantía de vida
Si la planta llega en mal estado, te la reponemos sin coste adicional.
📦
Eco-packaging
Materiales 100% reciclables y sin plástico de un solo uso.
💬
Cuidados incluidos
Cada pedido incluye una guía de cuidados personalizada para la especie.

Código generado

Archivos Liquid entregados, listos para desplegar con Shopify CLI

{% liquid %} {% schema %} {% render %} Storefront API Ajax Cart settings_schema.json
{% comment %} sections/hero-banner.liquid — Botánica Viva {% endcomment %}

<section class="hero"
  style="background-image: url('{{ section.settings.image | image_url: width: 1920 }}')">

  <div class="hero__content">
    <h1>{{ section.settings.heading }}</h1>
    <p>{{ section.settings.subtext }}</p>

    {% if section.settings.button_text != blank %}
      <a href="{{ section.settings.button_link }}"
         class="btn-primary">
        {{ section.settings.button_text }}
      </a>
    {% endif %}
  </div>
</section>

{% schema %}
{
  "name": "Hero Banner",
  "settings": [
    { "type": "image_picker", "id": "image", "label": "Imagen de fondo" },
    { "type": "text", "id": "heading",
      "label": "Título", "default": "Tu hogar, más verde" },
    { "type": "textarea", "id": "subtext", "label": "Subtexto" },
    { "type": "text", "id": "button_text", "label": "Texto del botón" },
    { "type": "url",  "id": "button_link", "label": "Enlace del botón" }
  ],
  "presets": [{ "name": "Hero Banner" }]
}
{% endschema %}
{% comment %} sections/featured-products.liquid {% endcomment %}

<section class="featured-products">
  <h2>{{ section.settings.title }}</h2>
  <div class="product-grid">
    {% for product in section.settings.collection.products
       limit: section.settings.limit %}
      {% render 'product-card', product: product %}
    {% endfor %}
  </div>
</section>

{% comment %} snippets/product-card.liquid {% endcomment %}

<div class="product-card">
  <a href="{{ product.url }}">
    <img src="{{ product.featured_image | image_url: width: 400 }}"
         alt="{{ product.featured_image.alt | escape }}"
         loading="lazy" width="400" height="400">
    <h3>{{ product.title }}</h3>
  </a>

  {% if product.compare_at_price > product.price %}
    <span class="price--sale">{{ product.price | money }}</span>
    <s>{{ product.compare_at_price | money }}</s>
  {% else %}
    <span>{{ product.price | money }}</span>
  {% endif %}

  <button data-variant-id="{{ product.variants.first.id }}"
          class="btn-cart js-add-to-cart">
    {% if product.available %}Añadir{% else %}Agotado{% endif %}
  </button>
</div>
// assets/cart.js — Ajax Cart sin recarga de página

async function addToCart(variantId, quantity = 1) {
  const res = await fetch('/cart/add.js', {
    method: 'POST',
    headers: { 'Content-Type': 'application/json' },
    body: JSON.stringify({
      items: [{ id: variantId, quantity }]
    })
  });
  const cart = await res.json();
  updateCartUI(cart);
  openCartDrawer();
}

async function updateQuantity(lineItemKey, quantity) {
  const res = await fetch('/cart/change.js', {
    method: 'POST',
    headers: { 'Content-Type': 'application/json' },
    body: JSON.stringify({ id: lineItemKey, quantity })
  });
  const cart = await res.json();
  updateCartUI(cart);
}

function updateCartUI(cart) {
  document.querySelector('.cart-count').textContent = cart.item_count;
  document.querySelector('.cart-total').textContent =
    formatMoney(cart.total_price);
}

// Delegación de eventos para botones dinámicos
document.addEventListener('click', e => {
  const btn = e.target.closest('.js-add-to-cart');
  if (btn) addToCart(btn.dataset.variantId);
});
// config/settings_schema.json — Botánica Viva

[
  {
    "name": "Colores de la marca",
    "settings": [
      {
        "type": "color", "id": "color_primary",
        "label": "Verde principal",
        "default": "#2d6a4f"
      },
      {
        "type": "color", "id": "color_accent",
        "label": "Terracota (acento)",
        "default": "#e07a5f"
      },
      {
        "type": "color", "id": "color_bg",
        "label": "Fondo crema",
        "default": "#fefae0"
      }
    ]
  },
  {
    "name": "Tipografía",
    "settings": [
      {
        "type": "font_picker", "id": "font_heading",
        "label": "Fuente títulos",
        "default": "playfair_display_n7"
      },
      {
        "type": "font_picker", "id": "font_body",
        "label": "Fuente texto",
        "default": "lato_n4"
      }
    ]
  },
  {
    "name": "Redes Sociales",
    "settings": [
      { "type": "text", "id": "social_instagram",
        "label": "Instagram" },
      { "type": "text", "id": "social_tiktok",
        "label": "TikTok" }
    ]
  }
]