Onboarding Brand Design Update: Fix in-context dialog click handling#8341
Open
mikescamell wants to merge 5 commits intodevelopfrom
Open
Conversation
Contributor
Author
This was referenced Apr 23, 2026
LukasPaczos
reviewed
Apr 27, 2026
…ayout Prepares the brand-design-update in-context dialog to intercept child touches during intro/transition animations so that tap-to-skip cannot leak through to option/primary/secondary buttons or to stale listeners on reused views.
…mation Taps on the brand-design-update in-context CTA during its intro/transition animation previously reached option/primary/secondary buttons, including stale listeners on option views reused from the previous CTA. The cardContainer is now a TouchInterceptingLinearLayout and intercepts child touches while animating; taps route to snapToFinished() as intended. Intercepting is cleared both on natural animation end and on tap-to-skip, so the fully settled card is fully interactive again. Asana: https://app.asana.com/1/137249556945/task/1214123398861719
…ransitions The in-context CTA→CTA transition previously animated only the description and visible includes to alpha 0, leaving the previous CTA's title at full alpha until typing re-started. Users saw the old title held in place while the rest of the card faded out, then snap to blank and re-type the new text. titleView is now part of the fade-out AnimatorSet so it fades alongside the rest of the content, and the title is explicitly blanked at fade-out end so the next typing pass starts from a clean slate instead of flashing the stale text for a frame. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
…loop The content-transition fade-out AnimatorSet was fire-and-forget, so a tap-to-skip during fade-out couldn't cancel it. snapToFinished set animationsSettled=true and cleared interceptChildTouches, but the uncancelled fade-out's onAnimationEnd then unconditionally ran typeAndFadeIn() — starting a fresh typing animation that had no intercept protection. Users reported needing multiple taps to skip and seeing the new title flash in full before re-typing. The fade-out AnimatorSet is now hoisted to a closure var and cancelled by snapToFinished. Its onAnimationEnd branches on animationsSettled: if a tap-to-skip fired, the branch invokes a new applySettledState helper that snaps content to final state; otherwise it runs typeAndFadeIn as before. AnimatorSet.cancel() dispatches onAnimationEnd synchronously, so setting animationsSettled=true before the cancel is load-bearing — a comment records the ordering invariant. A second comment at the top of showCta records the broader invariant that only one showCta is active at a time; overlapping invocations would let stale closure callbacks clobber shared view state. Asana: https://app.asana.com/1/137249556945/task/1214123398861719 Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
c95f624 to
c827f27
Compare
3309142 to
17407a4
Compare
…tter Mirrors the pattern in BrandDesignUpdateWelcomePage so toggling the animating flag automatically updates cardContainer.interceptChildTouches. Prevents future drift between the two values.
LukasPaczos
approved these changes
Apr 29, 2026
Comment on lines
+881
to
+882
| // Assumes one active showCta at a time — the intercept flag gates user advances until settled. | ||
| // Overlapping calls would let stale closure callbacks clobber shared view state. |
Contributor
There was a problem hiding this comment.
This comment seems misplaced now.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Task/Issue URL: https://app.asana.com/1/137249556945/task/1214123398861719
Description
Fixes several touch and click handling issues in the brand design update onboarding dialogs that occurred during or immediately after animations.
LinearLayoutcard container withTouchInterceptingLinearLayoutso the layout can block child touch events while an animation is running — prevents accidental button taps mid-transition.Steps to test this PR
In-context click handling
brandDesignUpdateandselftoggles; go through onboarding to a card with in-context CTAs (e.g. visit-site-options or end-CTA).UI changes
Note
Medium Risk
Touches core onboarding CTA animation/click handling; regressions could block CTA buttons or cause dialogs to get stuck if animation state is mishandled, but there are no security or data risks.
Overview
Improves the Brand Design Update onboarding CTA dialog animation flow to prevent user interactions from firing while the card is transitioning/typing.
Replaces the dialog card container with
TouchInterceptingLinearLayoutand toggles child-touch interception via a new sharedisAnimatingstate, ensuring taps during animations only trigger the tap-to-skip behavior.Refines transition logic by fading out the title with other content, adding an
applySettledStatesnap path, and cancelling any in-progress fade-out animator on tap-to-skip to avoid re-triggering typing/animation loops.Reviewed by Cursor Bugbot for commit 3138ceb. Bugbot is set up for automated code reviews on this repo. Configure here.