Help with hover states

Hi community

I'm hoping someone can help me.

I've got two words on separate rows. I've added a hover state to both words and when one word has the mouse hovered over it I want the other word to go to the hover state. This is working fine.

When either of the words are selected it takes the user to a layer with a pop-up. To close the layer I want the user to be able to click a close button or click the word again.

My problem: I click on one of the words with the hover state and don't move the mouse, the pop-up appears, I click the word again to close the pop-up, move the mouse away. The word I used goes back to the normal state but the other word stays in the hover state colour.

I've attached an example. If you click on Kelly, don't move your mouse and click on it again to remove the hover state, the word Watson stays red, I want it to go back to black.

Any help to cure this would be greatly appreciated.

Thanks.

3 Replies