@ -8,6 +8,7 @@ import { PageAddButton } from '@/ui/layout/page/components/PageAddButton';
|
||||
import { PageHeader } from '@/ui/layout/page/components/PageHeader';
|
||||
import { PageHotkeysEffect } from '@/ui/layout/page/components/PageHotkeysEffect';
|
||||
import { ViewType } from '@/views/types/ViewType';
|
||||
import { useIsFeatureEnabled } from '@/workspace/hooks/useIsFeatureEnabled';
|
||||
import { useContext } from 'react';
|
||||
import { useRecoilValue } from 'recoil';
|
||||
import { useIcons } from 'twenty-ui';
|
||||
@ -44,6 +45,10 @@ export const RecordIndexPageHeader = () => {
|
||||
onCreateRecord();
|
||||
};
|
||||
|
||||
const isPageHeaderV2Enabled = useIsFeatureEnabled(
|
||||
'IS_PAGE_HEADER_V2_ENABLED',
|
||||
);
|
||||
|
||||
return (
|
||||
<PageHeader title={pageHeaderTitle} Icon={Icon}>
|
||||
<PageHotkeysEffect onAddButtonClick={handleAddButtonClick} />
|
||||
@ -53,7 +58,7 @@ export const RecordIndexPageHeader = () => {
|
||||
) : (
|
||||
<RecordIndexPageKanbanAddButton />
|
||||
))}
|
||||
<PageHeaderOpenCommandMenuButton />
|
||||
{isPageHeaderV2Enabled && <PageHeaderOpenCommandMenuButton />}
|
||||
</PageHeader>
|
||||
);
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user