Delete WelcomeButton, remove TruthSocial remnants

revert-5af0e40a
Alex Gleason 2022-04-19 15:24:12 -05:00
rodzic 564524bfcc
commit 0c98157fb3
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: 7211D1F99744FBB7
4 zmienionych plików z 3 dodań i 65 usunięć

Wyświetl plik

@ -39,7 +39,7 @@ const allowedAroundShortCode = '><\u0085\u0020\u00a0\u1680\u2000\u2001\u2002\u20
const messages = defineMessages({
placeholder: { id: 'compose_form.placeholder', defaultMessage: 'What\'s on your mind?' },
spoiler_placeholder: { id: 'compose_form.spoiler_placeholder', defaultMessage: 'Write your warning here' },
publish: { id: 'compose_form.publish', defaultMessage: 'Truth' },
publish: { id: 'compose_form.publish', defaultMessage: 'Post' },
publishLoud: { id: 'compose_form.publish_loud', defaultMessage: '{publish}!' },
message: { id: 'compose_form.message', defaultMessage: 'Message' },
schedule: { id: 'compose_form.schedule', defaultMessage: 'Schedule' },

Wyświetl plik

@ -112,7 +112,7 @@ const Preferences = () => {
<Form>
<List>
<ListItem
label={<FormattedMessage id='home.column_settings.show_reblogs' defaultMessage='Show reTRUTHs' />}
label={<FormattedMessage id='home.column_settings.show_reblogs' defaultMessage='Show reposts' />}
hint={<FormattedMessage id='preferences.hints.feed' defaultMessage='In your home feed' />}
>
<SettingToggle settings={settings} settingPath={['home', 'shows', 'reblog']} onChange={onToggleChange} />

Wyświetl plik

@ -52,7 +52,7 @@ class BoostModal extends ImmutablePureComponent {
return (
<Modal
title='ReTruth?'
title='Repost?'
confirmationAction={this.handleReblog}
confirmationText={intl.formatMessage(buttonText)}
>

Wyświetl plik

@ -1,62 +0,0 @@
import PropTypes from 'prop-types';
import React from 'react';
import ImmutablePropTypes from 'react-immutable-proptypes';
import ImmutablePureComponent from 'react-immutable-pure-component';
import { defineMessages, injectIntl } from 'react-intl';
import { connect } from 'react-redux';
import { openComposeWithText } from 'soapbox/actions/compose';
import { Button } from 'soapbox/components/ui';
import emojify from 'soapbox/features/emoji/emoji';
const buildWelcomeMessage = account => (
`Yo @${account.get('acct')} nice to have you on TRUTH!
Here's the lay of the land...
Got suggestions? Post a TRUTH (<- this is what we call a post) & tag the @suggestions account.
Come across a bug? Feel free to let us know by tagging the @Bug account in a TRUTH! Screenshots encouraged!
Also, if you want to just chat about the product... feel free to drop some 💥 TRUTH 💣 on me! Tag @Billy!
Finally, make sure to invite only your favorite peeps by hitting Invites in the sidebar.`
);
const messages = defineMessages({
welcome: { id: 'account.welcome', defaultMessage: 'Welcome' },
});
const mapDispatchToProps = (dispatch) => ({
onClick(account) {
const text = buildWelcomeMessage(account);
dispatch(openComposeWithText(text));
},
});
export default @connect(undefined, mapDispatchToProps)
@injectIntl
class WelcomeButton extends ImmutablePureComponent {
static propTypes = {
intl: PropTypes.object.isRequired,
account: ImmutablePropTypes.record.isRequired,
onClick: PropTypes.func.isRequired,
};
handleClick = () => {
this.props.onClick(this.props.account);
}
render() {
const { intl } = this.props;
return (
<Button className='logo-button button--welcome' onClick={this.handleClick}>
<div dangerouslySetInnerHTML={{ __html: emojify('👋') }} />
{intl.formatMessage(messages.welcome)}
</Button>
);
}
}