From 688bf5e105ffcb253b9cfce2b58e44682238b491 Mon Sep 17 00:00:00 2001 From: padreug Date: Fri, 26 Sep 2025 23:57:56 +0200 Subject: [PATCH] feat: add cart summary button to StallView for improved user navigation - Introduced a cart summary button in StallView.vue that displays the total number of items in the cart. - Implemented a click handler to navigate users to the cart page, enhancing the shopping experience. - Imported the ShoppingCart icon from lucide-vue-next for visual representation. These changes provide users with quick access to their cart, improving overall usability and navigation within the market interface. --- src/modules/market/views/StallView.vue | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/src/modules/market/views/StallView.vue b/src/modules/market/views/StallView.vue index e557d14..28425e8 100644 --- a/src/modules/market/views/StallView.vue +++ b/src/modules/market/views/StallView.vue @@ -130,6 +130,13 @@ @add-to-cart="handleAddToCart" /> + +
+ +
@@ -147,7 +154,7 @@ import { SelectTrigger, SelectValue, } from '@/components/ui/select' -import { ArrowLeft, Store, X } from 'lucide-vue-next' +import { ArrowLeft, Store, X, ShoppingCart } from 'lucide-vue-next' import FuzzySearch from '@/components/ui/fuzzy-search/FuzzySearch.vue' import ProductGrid from '../components/ProductGrid.vue' import type { Product, Stall } from '../types/market' @@ -273,6 +280,10 @@ const handleAddToCart = (product: Product, quantity?: number) => { marketStore.addToStallCart(product, quantity || 1) } +const viewCart = () => { + router.push('/cart') +} + const viewStall = (otherStallId: string) => { if (otherStallId !== stallId.value) {