<svg xmlns="http://www.w3.org/2000/svg" style="display: none;">
<symbol id="interface-loader" viewBox="0 0 48 48">
<circle cx="24" cy="24" r="23"></circle>
- <circle cx="24" cy="24" fill="none" stroke="currentColor" stroke-width="3" r="16" stroke-dasharray="80 80"
- transform="rotate(102 24 24)">
- <animateTransform attributeName="transform" type="rotate" calcMode="linear" values="0 24 24;360 24 24"
- keyTimes="0;1" dur="1s" begin="0s" repeatCount="indefinite"></animateTransform>
+ <circle class="animate" cx="24" cy="24" fill="none" stroke="currentColor" stroke-width="3" r="16" stroke-dasharray="80 80"
+ transform="rotate(0 24 24)">
</circle>
</symbol>
<symbol id="interface-chevron" viewBox="0 0 512 512">
});
},
displayLoader: function () {
- $("#loader").show();
+ $("#loader").addClass('show');
if (!this.support.isMobile) {
$('body').addClass('loading');
}
if (!force && $('#splash').css('visibility') == 'visible') {
return;
}
- if (this.support.isMobile) {
- $("#loader").hide();
- } else {
- $("#loader").hide();
+ $("#loader").removeClass('show');
+ if (!this.support.isMobile) {
$('body').removeClass('loading');
}
},
}
+@keyframes loader-spin {
+ 0% {
+ transform: rotate(0deg);
+ }
+ 100% {
+ transform: rotate(360deg);
+ }
+}
+
/* Loader */
#loader {
position: absolute;
width: @loaderSize;
height: @loaderSize;
margin: @loaderMargin 0 0 @loaderMargin;
+ display: none;
+
svg {
width: 100%;
height: 100%;
fill: @loader-background-color;
color: @loader-foreground-color;
+ transform-origin: 50% 50%
+ }
+
+ &.show {
+ display: block;
+ svg {
+ animation-name: loader-spin;
+ animation-duration: 1s;
+ animation-iteration-count: infinite;
+ animation-timing-function: linear;
+ }
}
}