#101 Add loading spinner
This commit is contained in:
@@ -68,3 +68,26 @@ html {
|
||||
#download-all {
|
||||
margin: auto 4px auto auto;
|
||||
}
|
||||
|
||||
#loading-spinner {
|
||||
text-align: center;
|
||||
margin: 75px 0;
|
||||
}
|
||||
.loader {
|
||||
width: 48px;
|
||||
height: 48px;
|
||||
border: 5px solid #888;
|
||||
border-bottom-color: transparent;
|
||||
border-radius: 50%;
|
||||
display: inline-block;
|
||||
box-sizing: border-box;
|
||||
animation: rotation 1s linear infinite;
|
||||
}
|
||||
@keyframes rotation {
|
||||
0% {
|
||||
transform: rotate(0deg);
|
||||
}
|
||||
100% {
|
||||
transform: rotate(360deg);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -68,6 +68,9 @@ class LGallery {
|
||||
})
|
||||
this.index += PER_PAGE
|
||||
this.lightGallery.refresh()
|
||||
} else {
|
||||
// Remove the loading spinner once all items are loaded
|
||||
document.getElementById('loading-spinner')?.remove()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user