Skip to content

Instantly share code, notes, and snippets.

@bjankord
Created April 7, 2016 00:19
Show Gist options
  • Save bjankord/a3e47cf7893045a540594e24917e2da5 to your computer and use it in GitHub Desktop.
Save bjankord/a3e47cf7893045a540594e24917e2da5 to your computer and use it in GitHub Desktop.
Add
<img src="profile.png" class="avatar" alt="Jane Doe">
<img src="profile.png" class="avatar is-hovered" alt="Jane Doe">

Add a class you can use to mock hover styles when you run the visual regression test on the component. I'd stick with :hover in you site/app and just use the class for testing this state.

.avatar {
// img styles here
}
.avatar:hover,
.avatar.is-hovered {
// img hover styles here
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment