import React from 'react'; import { useCurrentPagePath, useCurrentPageId } from '~/stores/page'; import loggerFactory from '~/utils/logger'; import { PageRevisionTable } from '../PageHistory/PageRevisionTable'; import { useAutoComparingRevisionsByQueryParam } from './hooks'; const logger = loggerFactory('growi:PageHistory'); type PageHistoryProps = { onClose: () => void } export const PageHistory: React.FC = (props: PageHistoryProps) => { const { onClose } = props; const { data: currentPageId } = useCurrentPageId(); const { data: currentPagePath } = useCurrentPagePath(); const comparingRevisions = useAutoComparingRevisionsByQueryParam(); return (
{currentPageId != null && currentPagePath != null && ( )}
); };