From a77bf7ff6cc7aa23b19b2bbcc56c7a23b1b8ce0a Mon Sep 17 00:00:00 2001 From: Padreug Date: Thu, 21 May 2026 16:01:55 +0200 Subject: [PATCH] feat(activities): editingEvent in activities store MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Carry the LNbits event being edited at store level so the shell-mounted CreateEventDialog (activities-app/App.vue) can open in edit mode from anywhere a user surfaces their own event — most importantly the activity detail page, which is where they actually land when fixing a posting. Co-Authored-By: Claude Opus 4.7 (1M context) --- src/modules/activities/stores/activities.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/modules/activities/stores/activities.ts b/src/modules/activities/stores/activities.ts index 0387ea4..7c5160c 100644 --- a/src/modules/activities/stores/activities.ts +++ b/src/modules/activities/stores/activities.ts @@ -1,6 +1,7 @@ import { defineStore } from 'pinia' import { ref, computed } from 'vue' import type { Activity } from '../types/activity' +import type { TicketedEvent } from '../types/ticket' /** * Pinia store for cached activities from Nostr relays. @@ -14,6 +15,9 @@ export const useActivitiesStore = defineStore('activities', () => { /** Toggle by the standalone bottom-nav Create tab; mounted dialog lives * in activities-app/App.vue so it's available from every route. */ const showCreateDialog = ref(false) + /** When set, the shell-mounted CreateEventDialog opens in edit mode + * for this LNbits event. Cleared when the dialog closes. */ + const editingEvent = ref(null) // Computed const activities = computed(() => Array.from(activitiesMap.value.values())) @@ -88,6 +92,7 @@ export const useActivitiesStore = defineStore('activities', () => { isLoading, lastUpdated, showCreateDialog, + editingEvent, // Computed activities,