diff --git a/src/components/App/index.tsx b/src/components/App/index.tsx index 117082abc..bf355b12b 100644 --- a/src/components/App/index.tsx +++ b/src/components/App/index.tsx @@ -15,7 +15,6 @@ import { useAppStore } from '~/stores/useAppStore' import { useDataStore } from '~/stores/useDataStore' import { useFeatureFlagStore } from '~/stores/useFeatureFlagStore' import { useUpdateSelectedNode } from '~/stores/useGraphStore' -import { useModal } from '~/stores/useModalStore' import { useTeachStore } from '~/stores/useTeachStore' import { useUserStore } from '~/stores/useUserStore' import { @@ -54,18 +53,12 @@ const LazyMainToolbar = lazy(() => import('./MainToolbar').then(({ MainToolbar } const LazyUniverse = lazy(() => import('~/components/Universe').then(({ Universe }) => ({ default: Universe }))) const LazySideBar = lazy(() => import('./SideBar').then(({ SideBar }) => ({ default: SideBar }))) -const LazyOnboardingModal = lazy(() => - import('../ModalsContainer/OnboardingFlow').then(({ OnboardingModal }) => ({ default: OnboardingModal })), -) - export const App = () => { const [searchParams] = useSearchParams() const query = searchParams.get('q') const { setBudget, setNodeCount } = useUserStore((s) => s) const queueRef = useRef(null) const timerRef = useRef(null) - const { open, visible } = useModal('onboardingFlow') - const [isAdmin] = useUserStore((s) => [s.isAdmin, s.setPubKey]) const { setSidebarOpen, @@ -75,7 +68,6 @@ export const App = () => { setTranscriptOpen, universeQuestionIsOpen, setUniverseQuestionIsOpen, - appMetaData, } = useAppStore((s) => s) const setTeachMeAnswer = useTeachStore((s) => s.setTeachMeAnswer) @@ -330,16 +322,10 @@ export const App = () => { }, [runningProjectId, setRunningProjectMessages]) useEffect(() => { - if (!isAdmin && appMetaData?.title && !visible) { - open() - } - }, [isAdmin, appMetaData?.title, open, visible]) - - useEffect(() => { - if (!splashDataLoading && !visible) { + if (!splashDataLoading) { setUniverseQuestionIsOpen() } - }, [setUniverseQuestionIsOpen, splashDataLoading, visible]) + }, [setUniverseQuestionIsOpen, splashDataLoading]) return ( <> @@ -350,13 +336,7 @@ export const App = () => {