From 1df4f12e929f12ce451735c7a0e125527595c7cd Mon Sep 17 00:00:00 2001 From: Samir Boulahtit Date: Sun, 23 Nov 2025 06:23:25 +0100 Subject: [PATCH] fix: refactor product detail page to extend base template and use correct paths MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Issues resolved: - Product detail page was standalone HTML without proper styling - Referenced non-existent CSS files (/static/css/shared/base.css, /static/css/vendor/vendor.css) - Used wrong image path (/static/images/ instead of /static/shop/img/) - Missing header, footer, and navigation - Not integrated with shop layout system Changes: - Extend shop/base.html for consistent styling and layout - Remove hardcoded CSS references (now inherited from base) - Update image paths to /static/shop/img/placeholder.jpg - Integrate with shopLayoutData() for cart and toast functionality - Add proper breadcrumbs with landing page navigation - Use Tailwind classes consistent with other shop pages - Use theme CSS variables from base template The product detail page now has proper styling, navigation, and integrates seamlessly with the rest of the shop frontend. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude --- app/templates/shop/product.html | 1096 ++++++++++--------------------- 1 file changed, 356 insertions(+), 740 deletions(-) diff --git a/app/templates/shop/product.html b/app/templates/shop/product.html index 40a50e8a..33e46c71 100644 --- a/app/templates/shop/product.html +++ b/app/templates/shop/product.html @@ -1,771 +1,387 @@ - - - - - - {{ product.name if product else 'Product' }} - {{ vendor.name }} - - - - - -
- -
-
- ← Back to Products -

{{ vendor.name }}

-
- -
+{# app/templates/shop/product.html #} +{% extends "shop/base.html" %} - -
-
-
-

Loading product...

-
-
+{% block title %}{{ product.name if product else 'Product' }}{% endblock %} - -
-
- -
-
- -
+{# Alpine.js component #} +{% block alpine_data %}productDetail(){% endblock %} - - -
- - -
-

- - -
- - Brand: - - - Category: - - - SKU: - -
- - -
-
- - - SALE -
-
- -
-
- - -
- - ✓ In Stock ( available) - - - ✗ Out of Stock - -
- - -
-

Description

-

-
- - -
-

Product Details

-
    -
  • - GTIN: -
  • -
  • - Condition: -
  • -
  • - Color: -
  • -
  • - Size: -
  • -
  • - Material: -
  • -
-
- - -
- -
- -
- - - -
-
- - - - - -
- Total: -
-
-
-
- - - -
- - -
+{% block content %} +
+ {# Breadcrumbs #} + - - - - - \ No newline at end of file + })); +}); + +{% endblock %}