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
F3586917: D6052.id20166.diff
Mon, Dec 30, 12:32 AM
Unknown Object (File)
Fri, Dec 27, 2:45 AM
Unknown Object (File)
Thu, Dec 26, 9:03 AM
Unknown Object (File)
Mon, Dec 23, 3:45 PM
Unknown Object (File)
Mon, Dec 23, 9:15 AM
Unknown Object (File)
Tue, Dec 3, 4:33 AM
Unknown Object (File)
Nov 27 2024, 8:22 PM
Unknown Object (File)
Nov 27 2024, 8:20 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