From 77de3cd07880c7806e79be996f743e04b550d3a5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Milorad=20FIlipovi=C4=87?= Date: Tue, 22 Jul 2025 16:35:57 +0200 Subject: [PATCH] fix(editor): Only show AI starter pack experiment to cloud users (no-changelog) (#17550) --- .../stores/aiTemplatesStarterCollection.store.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/packages/frontend/editor-ui/src/experiments/aiTemplatesStarterCollection/stores/aiTemplatesStarterCollection.store.ts b/packages/frontend/editor-ui/src/experiments/aiTemplatesStarterCollection/stores/aiTemplatesStarterCollection.store.ts index 242cd57f6a..a3b66f03ce 100644 --- a/packages/frontend/editor-ui/src/experiments/aiTemplatesStarterCollection/stores/aiTemplatesStarterCollection.store.ts +++ b/packages/frontend/editor-ui/src/experiments/aiTemplatesStarterCollection/stores/aiTemplatesStarterCollection.store.ts @@ -12,6 +12,7 @@ import { usePostHog } from '@/stores/posthog.store'; import { TEMPLATE_ONBOARDING_EXPERIMENT } from '@/constants'; import { useLocalStorage } from '@vueuse/core'; import { useI18n } from '@n8n/i18n'; +import { useSettingsStore } from '@/stores/settings.store'; const LOCAL_STORAGE_SETTING_KEY = 'N8N_AI_TEMPLATES_STARTER_COLLECTION_CALL_OUT_DISMISSED'; @@ -24,14 +25,16 @@ export const useAITemplatesStarterCollectionStore = defineStore( const foldersStore = useFoldersStore(); const workflowsStore = useWorkflowsStore(); const posthogStore = usePostHog(); + const settingsStore = useSettingsStore(); const calloutDismissedRef = useLocalStorage(LOCAL_STORAGE_SETTING_KEY, false); const calloutDismissed = computed(() => calloutDismissedRef.value); const isFeatureEnabled = computed(() => { return ( + settingsStore.isCloudDeployment && posthogStore.getVariant(TEMPLATE_ONBOARDING_EXPERIMENT.name) === - TEMPLATE_ONBOARDING_EXPERIMENT.variantStarterPack + TEMPLATE_ONBOARDING_EXPERIMENT.variantStarterPack ); });