Repository navigation
Conversation
Co-authored-by: Situ Chandra Shil <situchan@users.noreply.github.com>
|
Hey! I see that you made changes to our Form component. Make sure to update the docs in FORMS.md accordingly. Cheers! |
Codecov Report✅ Changes either increased or maintained existing code coverage, great job!
|
|
🤖 Android test steps verification results: Verified on standalone Android NewDot: app and Workspace Rules opened, but Add rule hit a Control-plan upgrade gate. Keyboard regression checks were blocked, and the running PR revision could not be confirmed.
|
|
🤖 Web test steps verification results: Enabled Rules through More features and opened Rules successfully. Add rule displayed a paid Control-plan upgrade dialog; no upgrade was accepted, so form and typing checks remain blocked rather than product failures.
|
|
@MelvinBot which proposal did you implement? |
|
I implemented my proposal, as requested in your implementation comment: restore description visibility when typing resumes in an already-focused input, coalesce scroll requests, and preserve existing focus/refusal scrolling. |
| const scrollTo = (y: number) => { | ||
| const scrollTo = (y: number, animated = true) => { | ||
| if (!animated) { | ||
| formRef.current?.scrollTo({y: Math.max(y, 0), animated: false}); |
There was a problem hiding this comment.
@MelvinBot I prefer animated scroll when editing resumes.
Also if possible, extract new scroll logic into separate hook so it can be reused in other pages, not only DescribeRuleForm
There was a problem hiding this comment.
🤖 Web test steps verification results:
Pushed the update: resumed-edit scrolling now animates immediately, with recovery extracted into reusable useRevealEditedInput; 55 targeted tests, lint, typecheck, formatting, and Storybook smoke passed, while full Jest timed out. Browser verification was blocked by a blank dev-app screen.
| Step | Status |
|---|---|
Verify animated recovery when typing resumesBlocked: description form unreachable. |
|
Verify rapid/multiline editing and recovery after interrupted scrollingBlocked in browser; automated regression coverage passed. |
|
Verify unchanged initial-focus and refusal scrollingBlocked in browser; automated regression coverage passed. |
view run · no recording available
Co-authored-by: Situ Chandra Shil <situchan@users.noreply.github.com>
|
|
|
|
|
Closing as this caused multiple regressions |




Explanation of Change
Restore the description input's visibility when typing resumes without another focus event. The reusable
useRevealEditedInputhook tracks the input box and scroll viewport, coalesces edits into one animation frame, and requests an animated scroll only when the bounded input is obscured. The multiline input retains responsibility for scrolling its own text to the caret. Duplicate targets are suppressed for a bounded window so rapid typing does not restart every animation and interrupted web scrolling cannot permanently block recovery.Keep initial-focus scrolling, refusal scrolling, and form/draft handling unchanged. Cancel pending recovery on blur, submission, manual dragging, deactivation, and unmount; exclude the non-scrolling Describe modal. Separate animation from keyboard waiting in the form scroll options: editing starts an animated scroll immediately without queuing delayed keyboard-animation scrolls; existing callers keep their previous delayed animated behavior. Document hook integration and coordinate requirements in the forms guide.
Manual/native QA is left to
situchan, as requested. Native keyboard overlap and multiline caret visibility have not been verified by Melvin; a viewport smaller than the input still needs manual coverage.AI Tests
Contributor branch
No accessible contributor fork was found, so this draft uses an upstream branch. To copy it to your own fork:
Fixed Issues
$ #106059
PROPOSAL: #106059 (comment)
Tests
// TODO: The human co-author must fill out the tests you ran before marking this PR as "ready for review".
Offline tests
QA Steps
// TODO: The human co-author must fill out the QA tests you ran before marking this PR as "ready for review".
// TODO: These must be filled out, or the issue title must include "[No QA]."
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectionAvatar, I verified the components usingAvatarare working as expected)npm run compress-svg)Avataris modified, I verified thatAvataris working as expected in all cases)Designlabel and/or tagged@Expensify/designso the design team can review the changes.mainbranch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTeststeps.Screenshots/Videos
Android: Native
Android: mWeb Chrome
iOS: Native
iOS: mWeb Safari
MacOS: Chrome / Safari
Web verification blocker (not evidence that the scrolling fix passed):