// @flow import React from 'react'; import Button from 'component/button'; import FileDownloadLink from 'component/fileDownloadLink'; import { MODALS } from 'lbry-redux'; import classnames from 'classnames'; import * as icons from 'constants/icons'; type FileInfo = { claim_id: string, }; type Props = { uri: string, openModal: ({ id: string }, { uri: string }) => void, claimIsMine: boolean, fileInfo: FileInfo, vertical?: boolean, // should the buttons be stacked vertically? }; class FileActions extends React.PureComponent { render() { const { fileInfo, uri, openModal, claimIsMine, vertical } = this.props; const claimId = fileInfo ? fileInfo.claim_id : ''; const showDelete = fileInfo && Object.keys(fileInfo).length > 0; return (
{showDelete && (
); } } export default FileActions;