|
@@ -10,6 +10,7 @@ import { FC, useCallback, useEffect } from 'react'
|
|
|
import {
|
|
import {
|
|
|
canUseNewEditor,
|
|
canUseNewEditor,
|
|
|
useIsNewEditorEnabled,
|
|
useIsNewEditorEnabled,
|
|
|
|
|
+ useIsNewEditorEnabledViaPrimaryFeatureFlag,
|
|
|
} from '../../utils/new-editor-utils'
|
|
} from '../../utils/new-editor-utils'
|
|
|
import Notification from '@/shared/components/notification'
|
|
import Notification from '@/shared/components/notification'
|
|
|
import { useSwitchEnableNewEditorState } from '../../hooks/use-switch-enable-new-editor-state'
|
|
import { useSwitchEnableNewEditorState } from '../../hooks/use-switch-enable-new-editor-state'
|
|
@@ -30,14 +31,15 @@ export const IdeRedesignIntroModal: FC = () => {
|
|
|
name: TUTORIAL_KEY,
|
|
name: TUTORIAL_KEY,
|
|
|
}
|
|
}
|
|
|
)
|
|
)
|
|
|
|
|
+ const hasAccess = useIsNewEditorEnabledViaPrimaryFeatureFlag()
|
|
|
|
|
|
|
|
useEffect(() => {
|
|
useEffect(() => {
|
|
|
|
|
+ if (!hasAccess) return
|
|
|
if (!inactiveTutorials.includes(TUTORIAL_KEY)) {
|
|
if (!inactiveTutorials.includes(TUTORIAL_KEY)) {
|
|
|
tryShowingPopup()
|
|
tryShowingPopup()
|
|
|
}
|
|
}
|
|
|
- }, [tryShowingPopup, inactiveTutorials])
|
|
|
|
|
|
|
+ }, [tryShowingPopup, inactiveTutorials, hasAccess])
|
|
|
|
|
|
|
|
- const hasAccess = canUseNewEditor()
|
|
|
|
|
if (!hasAccess) {
|
|
if (!hasAccess) {
|
|
|
return null
|
|
return null
|
|
|
}
|
|
}
|