-
Notifications
You must be signed in to change notification settings - Fork 3.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(web): reference to new Inbox (#6299)
- Loading branch information
1 parent
488d141
commit 3bc42cb
Showing
15 changed files
with
621 additions
and
37 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,22 @@ | ||
import { useNavigate, useParams } from 'react-router-dom'; | ||
|
||
import { FeatureFlagsKeysEnum } from '@novu/shared'; | ||
import { useFeatureFlag } from '../../hooks'; | ||
import { ROUTES } from '../../constants/routes'; | ||
import { UpdateProviderSidebar } from './components/multi-provider/UpdateProviderSidebar'; | ||
import { UpdateProviderSidebar } from './components/multi-provider/v2'; | ||
import { UpdateProviderSidebar as UpdateProviderSidebarOld } from './components/multi-provider/UpdateProviderSidebar'; | ||
|
||
export function UpdateProviderPage() { | ||
const { integrationId } = useParams(); | ||
const navigate = useNavigate(); | ||
const isV2Enabled = useFeatureFlag(FeatureFlagsKeysEnum.IS_V2_ENABLED); | ||
|
||
const onClose = () => { | ||
navigate(ROUTES.INTEGRATIONS); | ||
}; | ||
|
||
return <UpdateProviderSidebar key={integrationId} isOpened onClose={onClose} integrationId={integrationId} />; | ||
return isV2Enabled ? ( | ||
<UpdateProviderSidebar key={integrationId} isOpened onClose={onClose} integrationId={integrationId} /> | ||
) : ( | ||
<UpdateProviderSidebarOld key={integrationId} isOpened onClose={onClose} integrationId={integrationId} /> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.