Skip to content

fix(touchable-ripple): clear a ripple left by a disabling press - #5268

Merged
Doberjohn merged 2 commits into
mainfrom
fix/touchable-ripple-disabled-press
Nov 20, 2026
Merged

Doberjohn merged 2 commits into
mainfrom
fix/touchable-ripple-disabled-press

Conversation

@Doberjohn

@Doberjohn Doberjohn commented Nov 20, 2026 •

Copy link
Copy Markdown
Collaborator

Motivation

On Android, a touchable that its own press disables (an onPressIn setting disabled) keeps the pressed ripple drawn, even after it's enabled again. TouchableRipple dropped android_ripple once disabled, and only the ripple's own press out clears the native pressed state. It's now kept while disabled; a disabled view never presses, so it draws nothing.

Related issue

Closes #5267. It comes from #5071.

Screenshots / Videos

Ripple rgba(255, 0, 0, 0.5), after that press and re-enabling. Before, then after (in RTL with the dynamic theme):


Test plan

On Android, press such a touchable, then enable it again: no tint is left. A disabled button still draws nothing when held.

The native pressed state is only cleared by the ripple's own press out,
and the ripple was dropped as soon as the touchable became disabled. A
press that disabled it left the pressed layer drawn, also after it was
enabled again. The ripple is now kept while disabled; a disabled view
never presses, so it shows nothing.
@Doberjohn Doberjohn added this to the 6.0.0-beta.0 milestone Nov 20, 2026
@Doberjohn
Doberjohn marked this pull request as ready for review November 20, 2026 14:51
Removed detailed comments regarding focus ring placement and touch handling logic.
@Doberjohn
Doberjohn merged commit 6158ef9 into main Nov 20, 2026
13 of 14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

TouchableRipple: on Android, a press that disables the touchable leaves its ripple drawn

1 participant