Bluesky app fork with some witchin' additions 💫

delay toast after posting (#9208)

authored by samuel.fm and committed by

GitHub 6414bda2 591fd262

+27 -25
+27 -25
src/view/com/composer/Composer.tsx
··· 564 564 onPostSuccess?.(postSuccessData) 565 565 } 566 566 onClose() 567 - Toast.show( 568 - <Toast.Outer> 569 - <Toast.Icon /> 570 - <Toast.Text> 571 - {thread.posts.length > 1 572 - ? _(msg`Your posts were sent`) 573 - : replyTo 574 - ? _(msg`Your reply was sent`) 575 - : _(msg`Your post was sent`)} 576 - </Toast.Text> 577 - {postUri && ( 578 - <Toast.Action 579 - label={_(msg`View post`)} 580 - onPress={() => { 581 - const {host: name, rkey} = new AtUri(postUri) 582 - navigation.navigate('PostThread', {name, rkey}) 583 - }}> 584 - <Trans context="Action to view the post the user just created"> 585 - View 586 - </Trans> 587 - </Toast.Action> 588 - )} 589 - </Toast.Outer>, 590 - {type: 'success'}, 591 - ) 567 + setTimeout(() => { 568 + Toast.show( 569 + <Toast.Outer> 570 + <Toast.Icon /> 571 + <Toast.Text> 572 + {thread.posts.length > 1 573 + ? _(msg`Your posts were sent`) 574 + : replyTo 575 + ? _(msg`Your reply was sent`) 576 + : _(msg`Your post was sent`)} 577 + </Toast.Text> 578 + {postUri && ( 579 + <Toast.Action 580 + label={_(msg`View post`)} 581 + onPress={() => { 582 + const {host: name, rkey} = new AtUri(postUri) 583 + navigation.navigate('PostThread', {name, rkey}) 584 + }}> 585 + <Trans context="Action to view the post the user just created"> 586 + View 587 + </Trans> 588 + </Toast.Action> 589 + )} 590 + </Toast.Outer>, 591 + {type: 'success'}, 592 + ) 593 + }, 500) 592 594 }, [ 593 595 _, 594 596 agent,