show which identity roars are being signed with in the composer placeholder
parent
0f18a0ad00
commit
28b2a700f0
|
@ -17,7 +17,12 @@ import Publisher from './publisher';
|
|||
import TextareaIcons from './textarea_icons';
|
||||
|
||||
const messages = defineMessages({
|
||||
placeholder: { id: 'compose_form.placeholder', defaultMessage: 'What is on your mind?' },
|
||||
placeholder: { id: 'compose_form.placeholder', defaultMessage: 'Roar shamelessly!' },
|
||||
placeholder_as: {
|
||||
id: 'compose_form.placeholder_as',
|
||||
defaultMessage: "Signing as {signature}.\nRoar shamelessly!",
|
||||
values: {signature: 'yourself'}
|
||||
},
|
||||
missingDescriptionMessage: { id: 'confirmations.missing_media_description.message',
|
||||
defaultMessage: 'At least one media attachment is lacking a description. Consider describing all media attachments for the visually impaired before sending your toot.' },
|
||||
missingDescriptionConfirm: { id: 'confirmations.missing_media_description.confirm',
|
||||
|
@ -70,6 +75,7 @@ class ComposeForm extends ImmutablePureComponent {
|
|||
onUnmount: PropTypes.func,
|
||||
onPaste: PropTypes.func,
|
||||
onMediaDescriptionConfirm: PropTypes.func,
|
||||
account: ImmutablePropTypes.map.isRequired,
|
||||
};
|
||||
|
||||
static defaultProps = {
|
||||
|
@ -297,9 +303,11 @@ class ComposeForm extends ImmutablePureComponent {
|
|||
suggestions,
|
||||
text,
|
||||
spoilersAlwaysOn,
|
||||
account,
|
||||
} = this.props;
|
||||
|
||||
let disabledButton = isSubmitting || isUploading || isChangingUpload || (!text.trim().length && !anyMedia);
|
||||
let signature = this.props.account.get('signature');
|
||||
|
||||
return (
|
||||
<div className='composer'>
|
||||
|
@ -331,7 +339,7 @@ class ComposeForm extends ImmutablePureComponent {
|
|||
|
||||
<AutosuggestTextarea
|
||||
ref={this.setAutosuggestTextarea}
|
||||
placeholder={intl.formatMessage(messages.placeholder)}
|
||||
placeholder={signature ? intl.formatMessage(messages.placeholder_as, {signature: signature}) : intl.formatMessage(messages.placeholder)}
|
||||
disabled={isSubmitting}
|
||||
value={this.props.text}
|
||||
onChange={this.handleChange}
|
||||
|
|
|
@ -22,6 +22,8 @@ import { changeLocalSetting } from 'flavours/glitch/actions/local_settings';
|
|||
|
||||
import { privacyPreference } from 'flavours/glitch/util/privacy_preference';
|
||||
|
||||
import { me } from 'flavours/glitch/util/initial_state';
|
||||
|
||||
const messages = defineMessages({
|
||||
missingDescriptionMessage: { id: 'confirmations.missing_media_description.message',
|
||||
defaultMessage: 'At least one media attachment is lacking a description. Consider describing all media attachments for the visually impaired before sending your toot.' },
|
||||
|
@ -68,6 +70,7 @@ function mapStateToProps (state) {
|
|||
spoilersAlwaysOn: spoilersAlwaysOn,
|
||||
mediaDescriptionConfirmation: state.getIn(['local_settings', 'confirm_missing_media_description']),
|
||||
preselectOnReply: state.getIn(['local_settings', 'preselect_on_reply']),
|
||||
account: state.getIn(['accounts', me]),
|
||||
};
|
||||
};
|
||||
|
||||
|
|
|
@ -82,6 +82,7 @@
|
|||
"compose_form.lock_disclaimer": "Your account is not {locked}. Anyone can join your pack to view your follower-only roars.",
|
||||
"compose_form.lock_disclaimer.lock": "locked",
|
||||
"compose_form.placeholder": "Roar shamelessly!",
|
||||
"compose_form.placeholder_as": "Signing as {signature}.\nRoar shamelessly!",
|
||||
"compose_form.poll.add_option": "Add a choice",
|
||||
"compose_form.poll.duration": "Poll duration",
|
||||
"compose_form.poll.option_placeholder": "Choice {number}",
|
||||
|
|
Loading…
Reference in New Issue