import React from 'react'; import { FormattedMessage } from 'react-intl'; import { Link } from 'react-router-dom'; import { Text, Widget } from 'soapbox/components/ui'; import { useAppSelector, useSoapboxConfig } from 'soapbox/hooks'; import SiteWallet from './site_wallet'; interface ICryptoDonatePanel { limit: number, } const CryptoDonatePanel: React.FC = ({ limit = 3 }): JSX.Element | null => { const addresses = useSoapboxConfig().get('cryptoAddresses'); const siteTitle = useAppSelector((state) => state.instance.title); if (limit === 0 || addresses.size === 0) { return null; } const more = addresses.size - limit; const hasMore = more > 0; return ( }> {hasMore && ( )} ); }; export default CryptoDonatePanel;