From 39f8364edb63214f27044c89f89c9104a832bfce Mon Sep 17 00:00:00 2001 From: Ruslan Bakiev <572431+veikab@users.noreply.github.com> Date: Thu, 22 Jan 2026 16:59:33 +0700 Subject: [PATCH] Improve catalog UX: remove category, add offers count, dynamic layout - ProductCard: remove category field, add offersCount display - CatalogPage: add fullWidthMap prop for map-only view - catalog/index: pass fullWidthMap based on selectMode - i18n: add offers pluralization --- app/components/catalog/ProductCard.vue | 10 ++++----- app/components/page/CatalogPage.vue | 30 +++++++++++++++++++++++--- app/pages/catalog/index.vue | 5 +++++ i18n/locales/en/catalog.json | 3 ++- i18n/locales/ru/catalog.json | 3 ++- 5 files changed, 41 insertions(+), 10 deletions(-) diff --git a/app/components/catalog/ProductCard.vue b/app/components/catalog/ProductCard.vue index 19b9ec0..88ae0d4 100644 --- a/app/components/catalog/ProductCard.vue +++ b/app/components/catalog/ProductCard.vue @@ -14,10 +14,10 @@ ]" > - - {{ product.name }} - {{ product.categoryName || t('catalogProduct.labels.category_unknown') }} - + {{ product.name }} + + {{ product.offersCount }} {{ t('catalog.offers', product.offersCount) }} + {{ product.description }} @@ -30,8 +30,8 @@ import { NuxtLink } from '#components' interface Product { uuid?: string | null name?: string | null - categoryName?: string | null description?: string | null + offersCount?: number | null } const props = defineProps<{ diff --git a/app/components/page/CatalogPage.vue b/app/components/page/CatalogPage.vue index 11038a8..0c88eae 100644 --- a/app/components/page/CatalogPage.vue +++ b/app/components/page/CatalogPage.vue @@ -30,10 +30,32 @@ - +