Improve copy text response time (#7358)

This commit is contained in:
Daniel Espino García 2023-05-19 13:48:00 +02:00 committed by GitHub
parent 265be35dce
commit 081f687a11
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -19,8 +19,8 @@ type Props = {
}
const CopyTextOption = ({bottomSheetId, postMessage, sourceScreen}: Props) => {
const handleCopyText = useCallback(async () => {
await dismissBottomSheet(bottomSheetId);
Clipboard.setString(postMessage);
await dismissBottomSheet(bottomSheetId);
showSnackBar({barType: SNACK_BAR_TYPE.MESSAGE_COPIED, sourceScreen});
}, [postMessage]);