mirror of https://github.com/ColorlibHQ/AdminLTE
preload improve
parent
d7269cf1a9
commit
36f82d7335
|
@ -39,6 +39,7 @@ const Default = {
|
|||
scrollbarAutoHide: 'l',
|
||||
panelAutoHeight: true,
|
||||
panelAutoHeightMode: 'min-height',
|
||||
preloadDuration: 200,
|
||||
loginRegisterAutoHeight: true
|
||||
}
|
||||
|
||||
|
@ -174,13 +175,16 @@ class Layout {
|
|||
setTimeout(() => {
|
||||
$('body.hold-transition').removeClass('hold-transition')
|
||||
}, 50)
|
||||
const $preloader = $(SELECTOR_PRELOADER)
|
||||
if ($preloader) {
|
||||
$preloader.css('height', 0)
|
||||
setTimeout(() => {
|
||||
$preloader.children().hide()
|
||||
}, 200)
|
||||
}
|
||||
|
||||
setTimeout(() => {
|
||||
const $preloader = $(SELECTOR_PRELOADER)
|
||||
if ($preloader) {
|
||||
$preloader.css('height', 0)
|
||||
setTimeout(() => {
|
||||
$preloader.children().hide()
|
||||
}, 200)
|
||||
}
|
||||
}, this._config.preloadDuration)
|
||||
}
|
||||
|
||||
_max(numbers) {
|
||||
|
|
|
@ -12,20 +12,6 @@ body,
|
|||
min-height: 100%;
|
||||
}
|
||||
|
||||
.preloader {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
background-color: $main-bg;
|
||||
height: 100vh;
|
||||
width: 100%;
|
||||
transition: height 200ms linear;
|
||||
position: fixed;
|
||||
left: 0;
|
||||
top: 0;
|
||||
z-index: $zindex-preloader;
|
||||
}
|
||||
|
||||
.wrapper {
|
||||
position: relative;
|
||||
|
||||
|
@ -662,7 +648,7 @@ body:not(.layout-fixed) {
|
|||
}
|
||||
|
||||
.dark-mode {
|
||||
background-color: lighten($dark, 7.5%) !important;
|
||||
background-color: $dark-main-bg;
|
||||
color: $white;
|
||||
|
||||
.breadcrumb-item {
|
||||
|
@ -683,8 +669,4 @@ body:not(.layout-fixed) {
|
|||
color: $white;
|
||||
}
|
||||
}
|
||||
.preloader {
|
||||
background-color: $dark;
|
||||
color: $white;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -0,0 +1,24 @@
|
|||
//
|
||||
// Core: Preloader
|
||||
//
|
||||
|
||||
.preloader {
|
||||
display: flex;
|
||||
background-color: $main-bg;
|
||||
height: 100vh;
|
||||
width: 100%;
|
||||
transition: height 200ms linear;
|
||||
position: fixed;
|
||||
left: 0;
|
||||
top: 0;
|
||||
z-index: $zindex-preloader;
|
||||
}
|
||||
|
||||
.dark-mode {
|
||||
.preloader {
|
||||
background-color: $dark-main-bg;
|
||||
color: $white;
|
||||
}
|
||||
}
|
||||
|
||||
//
|
Loading…
Reference in New Issue