Eliminate loading flash for welcome overlay
This commit is contained in:
parent
e91956d0f7
commit
bd21a1f7ff
5 changed files with 24 additions and 17 deletions
|
@ -198,22 +198,19 @@ $(document).ready(function () {
|
|||
OSM.Index = function(map) {
|
||||
var page = {};
|
||||
|
||||
page.pushstate = function(path) {
|
||||
page.pushstate = function() {
|
||||
$("#content").addClass("overlay-sidebar");
|
||||
map.invalidateSize({pan: false})
|
||||
.panBy([-350, 0], {animate: false});
|
||||
OSM.loadSidebarContent(path);
|
||||
page.load();
|
||||
};
|
||||
|
||||
page.load = function() {
|
||||
return map.getState();
|
||||
};
|
||||
|
||||
page.popstate = function(path) {
|
||||
page.popstate = function() {
|
||||
$("#content").addClass("overlay-sidebar");
|
||||
map.invalidateSize({pan: false});
|
||||
OSM.loadSidebarContent(path);
|
||||
};
|
||||
|
||||
page.unload = function() {
|
||||
|
|
|
@ -649,12 +649,22 @@ nav.secondary {
|
|||
}
|
||||
}
|
||||
|
||||
.welcome {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.overlay-sidebar #sidebar {
|
||||
position: absolute;
|
||||
z-index: 1000;
|
||||
height: auto;
|
||||
border-bottom-right-radius: 5px;
|
||||
overflow: hidden;
|
||||
.welcome {
|
||||
display: block;
|
||||
}
|
||||
#sidebar_content {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
|
||||
.welcome {
|
||||
|
|
|
@ -122,7 +122,7 @@ nav.secondary {
|
|||
}
|
||||
|
||||
#sidebar .welcome {
|
||||
display: none;
|
||||
display: none !important;
|
||||
}
|
||||
|
||||
.leaflet-top.leaflet-right {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue