Skip to content

Commit 98efefb

Browse files
committed
fix: interactable message content
1 parent 88421c9 commit 98efefb

1 file changed

Lines changed: 12 additions & 1 deletion

File tree

package/src/components/Message/MessageItemView/MessageContent.tsx

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -318,10 +318,21 @@ const MessageContentWithContext = (props: MessageContentPropsWithContext) => {
318318
</>
319319
);
320320

321+
// Drop the Pressable's single-focus-stop behavior when the message contains
322+
// interactive children (poll options, attachment cells, the quoted-reply
323+
// navigator, shared location). Without this, VO/TalkBack subsume those
324+
// children into the row's one announcement and they can't be activated.
325+
const hasInteractiveContent = !!(
326+
message.poll_id ||
327+
message.quoted_message ||
328+
message.attachments?.length ||
329+
message.shared_location
330+
);
331+
321332
return (
322333
<Pressable
323334
accessibilityHint={accessibilityHint}
324-
accessible={message.poll_id ? false : undefined}
335+
accessible={hasInteractiveContent ? false : undefined}
325336
disabled={preventPress}
326337
onLongPress={(event) => {
327338
if (onLongPress) {

0 commit comments

Comments
 (0)