import { Button, Gridicon } from '@automattic/components';
import { useTranslate } from 'i18n-calypso';
import { FunctionComponent, useRef, useState } from 'react';
import PopoverMenu from 'calypso/components/popover-menu';
import { backupDownloadPath, backupRestorePath } from 'calypso/my-sites/backup/paths';
interface Props {
rewindId: string;
showActions: boolean;
siteSlug: string;
children?: React.ReactNode;
}
const ActivityCardActionBar: FunctionComponent< Props > = ( {
children,
rewindId,
showActions = true,
siteSlug,
} ) => {
const actionMenuRef = useRef( null );
const translate = useTranslate();
const [ showMenu, setShowMenu ] = useState( false );
const toggleMenu = () => setShowMenu( ! showMenu );
const closeMenu = () => setShowMenu( false );
const renderActions = () => (
<>