File size: 1,274 Bytes
1e92f2d |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 |
import { localize, fixMe } from 'i18n-calypso';
import PropTypes from 'prop-types';
import { PureComponent } from 'react';
import { connect } from 'react-redux';
import EmptyContent from 'calypso/components/empty-content';
import LoggedOutFormLinks from 'calypso/components/logged-out-form/links';
import Main from 'calypso/components/main';
import { recordTracksEvent } from 'calypso/state/analytics/actions';
import HelpButton from './help-button';
class NoDirectAccessError extends PureComponent {
static propTypes = {
recordTracksEvent: PropTypes.func.isRequired,
translate: PropTypes.func.isRequired,
};
render() {
const { translate } = this.props;
return (
<Main className="jetpack-connect__main-error">
<EmptyContent
title={ fixMe( {
text: 'This URL should not be accessed directly',
newCopy: translate( 'This URL should not be accessed directly' ),
oldCopy: translate( 'Oops, this URL should not be accessed directly' ),
} ) }
action={ translate( 'Get back to Jetpack Connect screen' ) }
actionURL="/jetpack/connect"
/>
<LoggedOutFormLinks>
<HelpButton />
</LoggedOutFormLinks>
</Main>
);
}
}
export default connect( null, { recordTracksEvent } )( localize( NoDirectAccessError ) );
|