Skip to content

Commit

Permalink
Help Center: Fix chat in migration flow (#98375)
Browse files Browse the repository at this point in the history
  • Loading branch information
escapemanuele authored Jan 15, 2025
1 parent 1b424c2 commit 6c4f1c8
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import { HelpCenter } from '@automattic/data-stores';
import { HelpCenter, User as UserStore } from '@automattic/data-stores';
import { useDispatch } from '@wordpress/data';
import { useCallback } from 'react';
import AsyncLoad from 'calypso/components/async-load';

const HELP_CENTER_STORE = HelpCenter.register();

const AsyncHelpCenter = () => {
const AsyncHelpCenter: React.FC< { user: UserStore.CurrentUser | undefined } > = ( { user } ) => {
const { setShowHelpCenter } = useDispatch( HELP_CENTER_STORE );

const handleClose = useCallback( () => {
Expand All @@ -23,6 +23,7 @@ const AsyncHelpCenter = () => {
require="@automattic/help-center?stepper"
placeholder={ null }
handleClose={ handleClose }
currentUser={ user }
/>
);
};
Expand Down
2 changes: 1 addition & 1 deletion client/landing/stepper/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,7 @@ window.AppBoot = async () => {
id="notices"
/>
</BrowserRouter>
<AsyncHelpCenter />
<AsyncHelpCenter user={ user as UserStore.CurrentUser } />
{ 'development' === process.env.NODE_ENV && (
<AsyncLoad require="calypso/components/webpack-build-monitor" placeholder={ null } />
) }
Expand Down

0 comments on commit 6c4f1c8

Please sign in to comment.