I have setup an image lightbox using a Featherlight Gallery.
I'm using a loader animation like this:
http://github.com/noelboss/featherlight/wiki/Add-a-CSS-Only-Loader
However, the animation only shows when you first click on an image.
It you click "next image" then the lightbox is blank while the next image loads.
Test example (how to reproduce this issue):
Go here: http://jsfiddle.net/geraldo/w691hytm/
@-webkit-keyframes featherlightLoader {
0% {
-webkit-transform: rotate(0deg);
transform: rotate(0deg);
}
100% {
-webkit-transform: rotate(360deg);
transform: rotate(360deg);
}
}
@keyframes featherlightLoader {
0% {
-webkit-transform: rotate(0deg);
transform: rotate(0deg);
}
100% {
-webkit-transform: rotate(360deg);
transform: rotate(360deg);
}
}
.featherlight-loading .featherlight-content {
-webkit-animation: featherlightLoader 1s infinite linear;
animation: featherlightLoader 1s infinite linear;
background: transparent;
border: 8px solid #8f8f8f;
border-left-color: #fff;
border-radius: 80px;
width: 80px;
height: 80px;
min-width: 0;
}
.featherlight-loading .featherlight-content > * {
display: none !important;
}
.featherlight-loading .featherlight-close,
.featherlight-loading .featherlight-inner {
display: none;
}
You will see 3 thumbnail images in the bottom-right of the screen.
Click on the middle image of the birds. It will display a loading animation.
Click the "previous image" arrow. While loading the large image it shows nothing, just a blank white area.
Is the ".featherlight-loading" class not being called when you click "next image"? Do I need to add something to the css?
Thanks in advance.