<li className="list-inline-item mr-2">
<span class="pointer" onClick={linkEvent(this, this.handleSavePostClick)}>{post.saved ? i18n.t('unsave') : i18n.t('save')}</span>
</li>
+ <li className="list-inline-item mr-2">
+ <span class="pointer" onClick={linkEvent(this, this.handleCrossPostClick)}><T i18nKey="cross_post">#</T></span>
+ </li>
{this.myPost &&
<>
<li className="list-inline-item">
WebSocketService.Instance.savePost(form);
}
+ handleCrossPostClick(i: PostListing) {
+ let params = `?name=${i.props.post.name}`;
+ if (i.props.post.url) {
+ params += `&url=${i.props.post.url}`;
+ }
+ if (i.props.post.body) {
+ params += `&body=${i.props.post.body}`;
+ }
+ i.context.router.history.push(`/create_post${params}`);
+ }
+
handleModRemoveShow(i: PostListing) {
i.state.showRemoveDialog = true;
i.setState(i.state);
posts: 'Posts',
related_posts: 'These posts might be related',
cross_posts: 'This link has also been posted to:',
+ cross_post: 'cross-post',
comments: 'Comments',
number_of_comments:'{{count}} Comments',
remove_comment: 'Remove Comment',