Bluesky app fork with some witchin' additions 💫
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

disable saving drafts for replies (#9815)

authored by

Samuel Newman and committed by
GitHub
3197cbcf 017120b3

+51 -35
+51 -35
src/view/com/composer/Composer.tsx
··· 1141 1141 {!IS_WEBFooterSticky && footer} 1142 1142 </View> 1143 1143 1144 - <Prompt.Outer control={discardPromptControl}> 1145 - <Prompt.Content> 1146 - <Prompt.TitleText> 1147 - {composerState.draftId ? ( 1148 - <Trans>Save changes?</Trans> 1149 - ) : ( 1150 - <Trans>Save draft?</Trans> 1151 - )} 1152 - </Prompt.TitleText> 1153 - <Prompt.DescriptionText> 1154 - {composerState.draftId 1155 - ? _( 1156 - msg`You have unsaved changes to this draft, would you like to save them?`, 1157 - ) 1158 - : _(msg`Would you like to save this as a draft to edit later?`)} 1159 - </Prompt.DescriptionText> 1160 - </Prompt.Content> 1161 - <Prompt.Actions> 1162 - <Prompt.Action 1163 - cta={ 1164 - composerState.draftId 1165 - ? _(msg`Save changes`) 1166 - : _(msg`Save draft`) 1167 - } 1168 - onPress={handleSaveDraft} 1169 - color="primary" 1170 - /> 1171 - <Prompt.Action 1172 - cta={_(msg`Discard`)} 1173 - onPress={handleDiscard} 1174 - color="negative_subtle" 1175 - /> 1176 - <Prompt.Cancel /> 1177 - </Prompt.Actions> 1178 - </Prompt.Outer> 1144 + {replyTo ? ( 1145 + <Prompt.Basic 1146 + control={discardPromptControl} 1147 + title={_(msg`Discard draft?`)} 1148 + description="" 1149 + confirmButtonCta={_(msg`Discard`)} 1150 + confirmButtonColor="negative" 1151 + onConfirm={handleDiscard} 1152 + /> 1153 + ) : ( 1154 + <Prompt.Outer control={discardPromptControl}> 1155 + <Prompt.Content> 1156 + <Prompt.TitleText> 1157 + {composerState.draftId ? ( 1158 + <Trans>Save changes?</Trans> 1159 + ) : ( 1160 + <Trans>Save draft?</Trans> 1161 + )} 1162 + </Prompt.TitleText> 1163 + <Prompt.DescriptionText> 1164 + {composerState.draftId ? ( 1165 + <Trans> 1166 + You have unsaved changes to this draft, would you like to 1167 + save them? 1168 + </Trans> 1169 + ) : ( 1170 + <Trans> 1171 + Would you like to save this as a draft to edit later? 1172 + </Trans> 1173 + )} 1174 + </Prompt.DescriptionText> 1175 + </Prompt.Content> 1176 + <Prompt.Actions> 1177 + <Prompt.Action 1178 + cta={ 1179 + composerState.draftId 1180 + ? _(msg`Save changes`) 1181 + : _(msg`Save draft`) 1182 + } 1183 + onPress={handleSaveDraft} 1184 + color="primary" 1185 + /> 1186 + <Prompt.Action 1187 + cta={_(msg`Discard`)} 1188 + onPress={handleDiscard} 1189 + color="negative_subtle" 1190 + /> 1191 + <Prompt.Cancel /> 1192 + </Prompt.Actions> 1193 + </Prompt.Outer> 1194 + )} 1179 1195 </KeyboardAvoidingView> 1180 1196 </BottomSheetPortalProvider> 1181 1197 )