Skip to content

Commit 1297ee4

Browse files
joevilchesfacebook-github-bot
authored andcommitted
Back out "Allow text links to be navigatable via keyboard by default"
Summary: This was causing links to not ellipsize and be scrollable. Gonna revert while I see if I can workaround Differential Revision: D68596950
1 parent fae6edb commit 1297ee4

File tree

2 files changed

+1
-31
lines changed

2 files changed

+1
-31
lines changed

packages/react-native/ReactAndroid/src/main/java/com/facebook/react/views/text/ReactLinkMovementMethod.kt

Lines changed: 0 additions & 22 deletions
This file was deleted.

packages/react-native/ReactAndroid/src/main/java/com/facebook/react/views/text/ReactTextViewManager.java

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,7 @@ public void updateExtraData(ReactTextView view, Object extraData) {
9393
if (update.containsImages()) {
9494
TextInlineImageSpan.possiblyUpdateInlineImageSpans(spannable, view);
9595
}
96+
view.setText(update);
9697

9798
// If this text view contains any clickable spans, set a view tag and reset the accessibility
9899
// delegate so that these can be picked up by the accessibility system.
@@ -105,16 +106,7 @@ public void updateExtraData(ReactTextView view, Object extraData) {
105106
new ReactAccessibilityDelegate.AccessibilityLinks(clickableSpans, spannable));
106107
ReactAccessibilityDelegate.resetDelegate(
107108
view, view.isFocusable(), view.getImportantForAccessibility());
108-
// To enable navigation via keyboard, which is distinct from accessibility navigation.
109-
view.setMovementMethod(ReactLinkMovementMethod.INSTANCE);
110-
} else {
111-
view.setMovementMethod(null);
112-
view.setTag(R.id.accessibility_links, null);
113-
ReactAccessibilityDelegate.resetDelegate(
114-
view, view.isFocusable(), view.getImportantForAccessibility());
115109
}
116-
117-
view.setText(update);
118110
}
119111
}
120112

0 commit comments

Comments
 (0)