diff --git a/website_sale_aplicoop/static/src/css/components/product-card.css b/website_sale_aplicoop/static/src/css/components/product-card.css index ca0ff82..852270b 100644 --- a/website_sale_aplicoop/static/src/css/components/product-card.css +++ b/website_sale_aplicoop/static/src/css/components/product-card.css @@ -104,8 +104,13 @@ .product-tags { display: flex; flex-wrap: wrap; + align-content: center; gap: var(--ac-space-3xs); justify-content: center; + /* Reserved even when a product has no tags (rendered empty, aria-hidden — + see eskaera_shop_products), so the supplier/origin/price rows below line + up across every card in the grid row. Matches one row of .badge-km. */ + min-height: calc(var(--ac-text-2xs) * var(--ac-leading-tight) + 2 * var(--ac-space-3xs) + 2px); margin: 0; padding: 0; } @@ -126,15 +131,35 @@ /* ---------- Supplier & origin ---------- */ +/* Both rows are reserved even when empty (rendered aria-hidden — see + eskaera_shop_products) and clamped to a fixed line count, so the price row + below lines up across every card in the grid row regardless of which + products actually have a supplier name or an origin. */ .product-card .product-supplier, .product-card .product-origin { margin: 0; + overflow: hidden; font-size: var(--ac-text-xs); font-weight: var(--ac-weight-normal); text-align: center; color: var(--ac-text-secondary); } +.product-card .product-supplier { + display: -webkit-box; + -webkit-box-orient: vertical; + -webkit-line-clamp: 2; + line-clamp: 2; + min-height: calc(2em * var(--ac-leading-tight)); + overflow-wrap: break-word; +} + +.product-card .product-origin { + min-height: calc(1em * var(--ac-leading-tight)); + white-space: nowrap; + text-overflow: ellipsis; +} + .product-card .product-origin .fa { margin-right: var(--ac-space-3xs); } diff --git a/website_sale_aplicoop/views/sale_order_views.xml b/website_sale_aplicoop/views/sale_order_views.xml index 50b5616..1998e65 100644 --- a/website_sale_aplicoop/views/sale_order_views.xml +++ b/website_sale_aplicoop/views/sale_order_views.xml @@ -8,16 +8,17 @@ sale.order - - - + + + - + + diff --git a/website_sale_aplicoop/views/website_templates.xml b/website_sale_aplicoop/views/website_templates.xml index 274a896..a4f4e39 100644 --- a/website_sale_aplicoop/views/website_templates.xml +++ b/website_sale_aplicoop/views/website_templates.xml @@ -658,6 +658,10 @@
+
@@ -672,6 +676,9 @@
+ +