diff --git a/ui/desktop/src/utils/appInitialization.ts b/ui/desktop/src/utils/appInitialization.ts index 054142036cac..d4415d25e8a7 100644 --- a/ui/desktop/src/utils/appInitialization.ts +++ b/ui/desktop/src/utils/appInitialization.ts @@ -9,6 +9,7 @@ import { } from '../components/ConfigContext'; import { backupConfig, initConfig, readAllConfig, recoverConfig, validateConfig } from '../api'; import { COST_TRACKING_ENABLED } from '../updates'; +import { toastService } from '../toasts'; interface InitializationDependencies { getExtensions?: (b: boolean) => Promise; @@ -140,6 +141,13 @@ const initializeForRecipe = async ({ > & { recipeConfig: Recipe; }) => { + toastService.configure({ silent: false }); + + const loadingToastId = toastService.loading({ + title: `Loading recipe: ${recipeConfig.title}`, + msg: 'Setting up environment...', + }); + await initConfig(); await readAllConfig({ throwOnError: true }); @@ -148,6 +156,9 @@ const initializeForRecipe = async ({ addExtension, }); + toastService.dismiss(loadingToastId); + toastService.success({ title: 'Recipe loaded', msg: `Recipe is ready to use` }); + setPairChat((prevChat) => ({ ...prevChat, recipeConfig: recipeConfig,