import { FormattedMessage, defineMessages, injectIntl, } from 'react-intl' import { openModal } from '../actions/modal' import { repository, source_url, me, } from '../initial_state' import { DEFAULT_REL } from '../constants' import Text from './text' import Button from './button' const messages = defineMessages({ help: { id: 'getting_started.help', defaultMessage: 'Help' }, invite: { id: 'getting_started.invite', defaultMessage: 'Invite people' }, hotkeys: { id: 'navigation_bar.keyboard_shortcuts', defaultMessage: 'Hotkeys' }, security: { id: 'getting_started.security', defaultMessage: 'Security' }, about: { id: 'navigation_bar.info', defaultMessage: 'About' }, developers: { id: 'getting_started.developers', defaultMessage: 'Developers' }, terms: { id: 'getting_started.terms', defaultMessage: 'Terms of Service' }, dmca: { id: 'getting_started.dmca', defaultMessage: 'DMCA' }, salesTerms: { id: 'getting_started.terms_of_sale', defaultMessage: 'Terms of Sale' }, privacy: { id: 'getting_started.privacy', defaultMessage: 'Privacy Policy' }, logout: { id: 'navigation_bar.logout', defaultMessage: 'Logout' }, }) const mapDispatchToProps = (dispatch) => ({ onOpenHotkeys() { dispatch(openModal('HOTKEYS')) }, }) export default @connect(null, mapDispatchToProps) @injectIntl class LinkFooter extends PureComponent { static propTypes = { intl: PropTypes.object.isRequired, onOpenHotkeys: PropTypes.func.isRequired, } render() { const { onOpenHotkeys, intl } = this.props const currentYear = new Date().getFullYear() const linkFooterItems = [ { href: 'https://help.gab.com', text: intl.formatMessage(messages.help), requiresUser: true, }, // : todo : // { // onClick: onOpenHotkeys, // text: intl.formatMessage(messages.hotkeys), // requiresUser: true, // }, { href: '/auth/edit', text: intl.formatMessage(messages.security), requiresUser: true, }, { to: '/about', text: intl.formatMessage(messages.about), }, { href: '/settings/applications', text: intl.formatMessage(messages.developers), }, { to: '/about/tos', text: intl.formatMessage(messages.terms), }, { to: '/about/dmca', text: intl.formatMessage(messages.dmca), }, { to: '/about/sales', text: intl.formatMessage(messages.salesTerms), }, { to: '/about/privacy', text: intl.formatMessage(messages.privacy), }, { href: '/auth/sign_out', text: intl.formatMessage(messages.logout), requiresUser: true, logout: true, }, ] return (
© {currentYear} Gab AI, Inc. {repository} ) }} />
) } }