Reputation: 51
I followed the details in the link for creating a image gallery.
And that approach works fine for me.
I want to change the mouse hover
event to a click
event so that when a thumbnail is clicked (instead of hover), its open image in large area.
Upvotes: 3
Views: 12483
Reputation: 10254
Something like this:
The old hover classes become focus:
.thumbnail:focus{
background-color: transparent;
outline:none;
}
.thumbnail:focus img{
border: 1px solid blue;
}
and the old html simply has tabindex added like follows for each anchor:
<a class="thumbnail" href="#thumb" tabindex="1">
Upvotes: 7