// @flow import * as ICONS from 'constants/icons'; import * as MODALS from 'constants/modal_types'; import * as PAGES from 'constants/pages'; import React, { PureComponent } from 'react'; import Button from 'component/button'; import Spinner from 'component/spinner'; import HelpLink from 'component/common/help-link'; import CreditAmount from 'component/common/credit-amount'; type Props = { uri: string, claim: StreamClaim, fileInfo: FileListItem, metadata: StreamMetadata, openFolder: (string) => void, contentType: string, user: ?any, pendingAmount: string, openModal: (id: string, { uri: string }) => void, claimIsMine: boolean, }; class FileValues extends PureComponent { render() { const { uri, claim, metadata, openModal, pendingAmount, claimIsMine } = this.props; if (!claim || !metadata) { return {__('Empty claim or metadata info.')}; } const supportsAmount = claim && claim.meta && claim.meta.support_amount && Number(claim.meta.support_amount); const purchaseReceipt = claim && claim.purchase_receipt; return ( {purchaseReceipt && ( )}
{__('Purchase Amount')}
{__('Original Publish Amount')} {claim && claim.amount ? :

...

}
{__('Supports and Tips')} {claimIsMine && !pendingAmount && Boolean(supportsAmount) && ( <>
{__('Total Staked Amount')}
{__('Community Choice?')}
); } } export default FileValues;