HomePhabricator
Diffusion Comm 85e81b1dc273

[web] Reset tooltip label after a timeout

Description

[web] Reset tooltip label after a timeout

Summary:
After the previous diff successful action results in updating the label. The problem is that the label will remain updated for the life of the component. In our approach it causes issues because only closing a thread will result in the component being unmounted. So we can't rely on unmounting when resetting the value.

We could try resetting the value on mouse leave, but without significant changes, it isn't possible in this hook to know that the pointer exited the whole tooltip / message. In this hook we can only detect if a pointer exited an icon, but that approach could result in the feedback being shown only for a short period and probably changing unexpectedly to the user.

The solution to these might be a timeout which makes the success message being displayed for some time.

Depends on D6084

Test Plan: Added a couple of console logs to check if the message is updated and if the timeout is cleared after the component unmounts (a thread is switched).

Reviewers: kamil, inka, ginsu, przemek, ashoat

Reviewed By: kamil, ashoat

Subscribers: ashoat, atul

Differential Revision: https://phab.comm.dev/D6087

Details

Provenance
tomekAuthored on Dec 29 2022, 1:26 AM
Reviewer
kamil
Differential Revision
D6087: [web] Reset tooltip label after a timeout
Parents
rCOMM3277d9295450: [web] Check if copy operation is successful
Branches
Unknown
Tags
Unknown