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)
Sun, Nov 24, 4:07 AM
Unknown Object (File)
Sun, Nov 24, 12:23 AM
Unknown Object (File)
Sat, Nov 16, 12:02 AM
Unknown Object (File)
Wed, Nov 13, 5:26 AM
Unknown Object (File)
Wed, Nov 13, 5:25 AM
Unknown Object (File)
Wed, Nov 13, 5:25 AM
Unknown Object (File)
Wed, Nov 13, 5:25 AM
Unknown Object (File)
Mon, Nov 4, 3:32 AM

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
No Lint Coverage
Unit
No Test Coverage

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