diff options
author | Takeshi Umeda <noel.yoshiba@gmail.com> | 2019-06-02 17:05:54 +0900 |
---|---|---|
committer | multiple creatures <dev@multiple-creature.party> | 2020-02-22 01:27:57 -0600 |
commit | 957d51312c9708d4d2e5f476719ce06c7b039958 (patch) | |
tree | 76b2e27a432ff3d96ba3ce46e669418189c7297b /app/javascript/flavours/glitch/features/compose | |
parent | d105cb4a1e356bb54d0ad067aea76b11115b9408 (diff) |
port glitch-soc@`1329308` to monsterfork: [Glitch] Improvement variable height in single column layout
Port d93b82af87de90eaa29eb54a423722fb9fb45b38 to glitch-soc Signed-off-by: Thibaut Girka <thib@sitedethib.com>
Diffstat (limited to 'app/javascript/flavours/glitch/features/compose')
-rw-r--r-- | app/javascript/flavours/glitch/features/compose/components/compose_form.js | 53 |
1 files changed, 25 insertions, 28 deletions
diff --git a/app/javascript/flavours/glitch/features/compose/components/compose_form.js b/app/javascript/flavours/glitch/features/compose/components/compose_form.js index 133f483ab..8957def09 100644 --- a/app/javascript/flavours/glitch/features/compose/components/compose_form.js +++ b/app/javascript/flavours/glitch/features/compose/components/compose_form.js @@ -21,12 +21,10 @@ const messages = defineMessages({ placeholder_as: { id: 'compose_form.placeholder_as', defaultMessage: "Signing as {nickname}.\nRoar shamelessly!", - values: {nickname: 'yourself'} + values: { nickname: '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', - defaultMessage: 'Send anyway' }, + 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', defaultMessage: 'Send anyway' }, spoiler_placeholder: { id: 'compose_form.spoiler_placeholder', defaultMessage: 'Write your warning here' }, }); @@ -350,32 +348,31 @@ class ComposeForm extends ImmutablePureComponent { /> </div> - <div className='composer--textarea'> - <TextareaIcons advancedOptions={advancedOptions} /> - - <AutosuggestTextarea - ref={this.setAutosuggestTextarea} - placeholder={nickname ? intl.formatMessage(messages.placeholder_as, {nickname: nickname}) : intl.formatMessage(messages.placeholder)} - disabled={isSubmitting} - value={this.props.text} - onChange={this.handleChange} - suggestions={this.props.suggestions} - onFocus={this.handleFocus} - onKeyDown={this.handleKeyDown} - onSuggestionsFetchRequested={onFetchSuggestions} - onSuggestionsClearRequested={onClearSuggestions} - onSuggestionSelected={this.onSuggestionSelected} - onPaste={onPaste} - autoFocus={!showSearch && !isMobile(window.innerWidth, layout)} - /> - + <div className='emoji-picker-wrapper'> <EmojiPicker onPickEmoji={handleEmoji} /> </div> - <div className='compose-form__modifiers'> - <UploadFormContainer /> - <PollFormContainer /> - </div> + <AutosuggestTextarea + ref={this.setAutosuggestTextarea} + placeholder={nickname ? intl.formatMessage(messages.placeholder_as, { nickname: nickname }) : intl.formatMessage(messages.placeholder)} + disabled={isSubmitting} + value={this.props.text} + onChange={this.handleChange} + suggestions={this.props.suggestions} + onFocus={this.handleFocus} + onKeyDown={this.handleKeyDown} + onSuggestionsFetchRequested={onFetchSuggestions} + onSuggestionsClearRequested={onClearSuggestions} + onSuggestionSelected={this.onSuggestionSelected} + onPaste={onPaste} + autoFocus={!showSearch && !isMobile(window.innerWidth, layout)} + > + <TextareaIcons advancedOptions={advancedOptions} /> + <div className='compose-form__modifiers'> + <UploadFormContainer /> + <PollFormContainer /> + </div> + </AutosuggestTextarea> <OptionsContainer advancedOptions={advancedOptions} |