Page MenuHomePhabricator

[web] Keyboard support for typeahead [12/13] - Scrolling thourgh overlay as user interacts with it
ClosedPublic

Authored by przemek on Dec 27 2022, 5:21 AM.
Tags
None
Referenced Files
Unknown Object (File)
Tue, Apr 9, 2:42 AM
Unknown Object (File)
Tue, Apr 9, 2:42 AM
Unknown Object (File)
Tue, Apr 9, 2:42 AM
Unknown Object (File)
Tue, Apr 9, 2:42 AM
Unknown Object (File)
Tue, Apr 9, 2:42 AM
Unknown Object (File)
Wed, Apr 3, 5:53 PM
Unknown Object (File)
Mar 17 2024, 11:20 PM
Unknown Object (File)
Mar 13 2024, 8:55 PM

Details

Summary

Overlay scrolls automatically when users moves through users suggested to mention.

Test Plan

Tested on video below:

Diff Detail

Repository
rCOMM Comm
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

tomek requested changes to this revision.Jan 4 2023, 6:30 AM
tomek added inline comments.
web/chat/typeahead-tooltip.react.js
149 ↗(On Diff #20179)

Maybe we should use scrollTo method?

web/utils/typeahead-utils.js
164–178 ↗(On Diff #20179)

This is a little complicated - could you add some tests?

This revision now requires changes to proceed.Jan 4 2023, 6:30 AM
przemek marked an inline comment as done.

Used scrollTo.
Added tests and run them.
There were some problems that I solved locally using fixes from here: https://linear.app/comm/issue/ENG-2654/problems-with-jest
I haven't pushed those fixes anywhere as it is to be discussed yet, but I found it acceptable to
push tests even if they fail currently (due to lack of mocks as mentioned on linear).
Similar thing is happening to tooltip-utils.test.js tests and it was ignored in the past I guess.

Used scrollTo.
Added tests and run them.
There were some problems that I solved locally using fixes from here: https://linear.app/comm/issue/ENG-2654/problems-with-jest
I haven't pushed those fixes anywhere as it is to be discussed yet, but I found it acceptable to
push tests even if they fail currently (due to lack of mocks as mentioned on linear).
Similar thing is happening to tooltip-utils.test.js tests and it was ignored in the past I guess.

It's interesting, because it seems like the tests should've failed on the CI - but it doesn't seem so. Do we know if these were run at all?

This revision is now accepted and ready to land.Jan 5 2023, 7:57 AM

I think they're not. They also don't fail on local tests. I'm not sure why. When I run yarn test in web, tests in tooltip failed as well, and they were failing for a long time I guess.

Did we create a task for the tests not being run?

No, I'll do it right now