After a user clicks to link with target="_blank" link opens the second tab, then the user decides to get back to the previous page (to the first tab) where the user came from with current link.
Till moment user will not drag the cursor to document (page) itself, :hover styling effects still will be there.
Here is simple code example:
.wrapper {
position: relative;
}
.wrapper:hover .tooltip {
transition: 'opacity 0.5s step-end';
opacity: 1;
}
.tooltip {
position: absolute;
height: 20px;
background-color: black;
opacity: 0;
color: white;
padding: 5px 10px;
border-radius: 5px;
opacity: 0;
}
<div class="wrapper">
<a target="_blank" href="https://www.google.com/">Google</a>
<div class="tooltip">
Tooltip
</div>
</div>
And actually code can be even easier, I just described my case above, here is a more basic example:
a:hover {
background-color: red;
}
<a href="https://www.google.com" target="_blank">Google</a>
That's happening only in Chrome (84.0.4147.125). To make it easier for you to understand the problem, I made screen-recording. Also might happen only in macOS, didn't check on Windows/Linux.
Is it possible somehow to fix it and make it work as other browsers do? After switching tabs, :hover effects are disappearing immediately without waiting till user bring the cursor to page.