From cc29f25b87d44daf5da2d3ef702ea29a333630b5 Mon Sep 17 00:00:00 2001 From: Fire Demon Date: Sat, 15 Aug 2020 21:41:55 -0500 Subject: [UI] Non-destructive conversion of reply to non-reply, add clear button --- .../flavours/glitch/features/compose/components/compose_form.js | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'app/javascript/flavours/glitch/features/compose/components/compose_form.js') 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 adaf063ee..aa97f864a 100644 --- a/app/javascript/flavours/glitch/features/compose/components/compose_form.js +++ b/app/javascript/flavours/glitch/features/compose/components/compose_form.js @@ -151,6 +151,10 @@ class ComposeForm extends ImmutablePureComponent { this.handleSubmit(sideArm === 'none' ? null : sideArm); } + handleClearAll = () => { + this.props.onClearAll(); + } + // Selects a suggestion from the autofill. onSuggestionSelected = (tokenStart, token, value) => { this.props.onSuggestionSelected(tokenStart, token, value, ['text']); @@ -258,6 +262,7 @@ class ComposeForm extends ImmutablePureComponent { handleSecondarySubmit, handleSelect, handleSubmit, + handleClearAll, handleRefTextarea, } = this; const { @@ -360,6 +365,7 @@ class ComposeForm extends ImmutablePureComponent { disabled={disabledButton} onSecondarySubmit={handleSecondarySubmit} onSubmit={handleSubmit} + onClearAll={handleClearAll} privacy={privacy} privacyWarning={privacyWarning} sideArm={sideArm} -- cgit