Fade the map in after it is done loading
This commit is contained in:
@@ -75,6 +75,12 @@ const RecordSheet = new function () {
|
||||
};
|
||||
};
|
||||
|
||||
const mapPlaceholder = document.querySelector('.map-placeholder');
|
||||
document.querySelector('object').addEventListener('load', function () {
|
||||
mapPlaceholder.remove();
|
||||
this.style.opacity = 1;
|
||||
});
|
||||
|
||||
window.addEventListener('load', () => {
|
||||
const svg = document.querySelector('object').contentDocument.querySelector('svg'),
|
||||
game = new Game(svg);
|
||||
|
||||
Reference in New Issue
Block a user