mirror of
https://github.com/signalapp/Signal-Desktop.git
synced 2026-05-08 08:58:38 +01:00
Fix keyboard handling in ReactionPicker/Viewer and their child views
This commit is contained in:
committed by
Fedor Indutnyy
parent
0bf77fadd3
commit
03b750d072
@@ -35,6 +35,13 @@ export const ReactionPickerPickerEmojiButton = React.forwardRef<
|
||||
event.stopPropagation();
|
||||
onClick();
|
||||
}}
|
||||
onKeyDown={event => {
|
||||
if (event.key === 'Enter' || event.key === 'Space') {
|
||||
event.stopPropagation();
|
||||
event.preventDefault();
|
||||
onClick();
|
||||
}
|
||||
}}
|
||||
>
|
||||
<Emoji size={48} emoji={emoji} title={title} />
|
||||
</button>
|
||||
@@ -54,6 +61,13 @@ export const ReactionPickerPickerMoreButton = ({
|
||||
event.stopPropagation();
|
||||
onClick();
|
||||
}}
|
||||
onKeyDown={event => {
|
||||
if (event.key === 'Enter' || event.key === 'Space') {
|
||||
event.stopPropagation();
|
||||
event.preventDefault();
|
||||
onClick();
|
||||
}
|
||||
}}
|
||||
tabIndex={0}
|
||||
title={i18n('Reactions--more')}
|
||||
type="button"
|
||||
|
||||
Reference in New Issue
Block a user