diff --git a/src/modules/chat/components/ChatComponent.vue b/src/modules/chat/components/ChatComponent.vue index 82ab49f..f893e2d 100644 --- a/src/modules/chat/components/ChatComponent.vue +++ b/src/modules/chat/components/ChatComponent.vue @@ -158,7 +158,7 @@ : 'bg-muted' ]" > - +

{{ message.content }}

{{ formatTime(message.created_at) }}

@@ -325,7 +325,7 @@ : 'bg-muted' ]" > - +

{{ message.content }}

{{ formatTime(message.created_at) }}

@@ -376,7 +376,6 @@ import { Badge } from '@/components/ui/badge' import { ScrollArea } from '@/components/ui/scroll-area' import { Avatar, AvatarImage, AvatarFallback } from '@/components/ui/avatar' import { useChat } from '../composables/useChat' -import ChatMessageContent from './ChatMessageContent.vue' import { useFuzzySearch } from '@/composables/useFuzzySearch' diff --git a/src/modules/chat/components/ChatMessageContent.vue b/src/modules/chat/components/ChatMessageContent.vue deleted file mode 100644 index f6d1ef9..0000000 --- a/src/modules/chat/components/ChatMessageContent.vue +++ /dev/null @@ -1,115 +0,0 @@ - - - diff --git a/src/modules/market/components/MarketSettings.vue b/src/modules/market/components/MarketSettings.vue index 0c2fccd..f636dcc 100644 --- a/src/modules/market/components/MarketSettings.vue +++ b/src/modules/market/components/MarketSettings.vue @@ -389,18 +389,14 @@ const onSubmit = form.handleSubmit(async (values) => { throw new Error('No wallet admin key available') } - // Build full stall object with updated values (API requires PUT with full object) - const stallToUpdate = { - ...currentStall.value, + // Update the stall with new values + const updatedStall = await nostrmarketAPI.updateStall(adminKey, currentStall.value.id, { name: values.name, config: { - ...currentStall.value.config, description: values.description || '', image_url: values.imageUrl || undefined } - } - - const updatedStall = await nostrmarketAPI.updateStall(adminKey, stallToUpdate) + }) currentStall.value = updatedStall toast.success('Store settings saved successfully!') diff --git a/src/modules/market/services/nostrmarketAPI.ts b/src/modules/market/services/nostrmarketAPI.ts index 170cee7..528336f 100644 --- a/src/modules/market/services/nostrmarketAPI.ts +++ b/src/modules/market/services/nostrmarketAPI.ts @@ -331,17 +331,23 @@ export class NostrmarketAPI extends BaseService { /** * Update an existing stall - * Note: The LNbits API uses PUT and expects the full stall object */ async updateStall( walletAdminkey: string, - stallData: Stall + stallId: string, + stallData: Partial<{ + name: string + config: { + description?: string + image_url?: string + } + }> ): Promise { const stall = await this.request( - `/api/v1/stall/${stallData.id}`, + `/api/v1/stall/${stallId}`, walletAdminkey, { - method: 'PUT', + method: 'PATCH', body: JSON.stringify(stallData), } ) diff --git a/src/modules/market/views/CheckoutPage.vue b/src/modules/market/views/CheckoutPage.vue index 8cb5378..a5cbdb7 100644 --- a/src/modules/market/views/CheckoutPage.vue +++ b/src/modules/market/views/CheckoutPage.vue @@ -14,7 +14,7 @@ - @@ -46,8 +46,8 @@
-
@@ -68,7 +68,7 @@
- +

{{ item.product.name }}

@@ -76,7 +76,7 @@

Quantity: {{ item.quantity }}

- +

@@ -108,76 +108,121 @@ - - + + - Shipping & Contact - Select shipping and provide your contact details + Shipping Information + Select your shipping zone - + -

- -
-
-
-
-

{{ zone.name }}

-

- {{ zone.countries?.join(', ') || 'Available' }} - - • No shipping required - -

-

- {{ zone.description }} -

-
-
-

- {{ formatPrice(zone.cost, checkoutCart.currency) }} -

-

shipping

-
+
+
+
+
+

{{ zone.name }}

+

+ {{ zone.countries?.join(', ') || 'Available' }} + + • No shipping required + +

+

+ {{ zone.description }} +

+
+
+

+ {{ formatPrice(zone.cost, checkoutCart.currency) }} +

+

shipping

- -
+ +

This merchant hasn't configured shipping zones yet.

Please contact the merchant for shipping information.

- -
+ +
+ +
+ + - -
- -