Various fixes for browser compatibility issues (#12740)
* Replace Math.log2 with ol/math.log2 * TypedArray.from() browser compatibility fallback * listen for input and change events for range
This commit is contained in:
@@ -179,8 +179,9 @@ const featureOverlay = new VectorLayer({
|
||||
}),
|
||||
});
|
||||
|
||||
document.getElementById('time').addEventListener('input', function () {
|
||||
const value = parseInt(this.value, 10) / 100;
|
||||
const control = document.getElementById('time');
|
||||
const listener = function () {
|
||||
const value = parseInt(control.value, 10) / 100;
|
||||
const m = time.start + time.duration * value;
|
||||
vectorSource.forEachFeature(function (feature) {
|
||||
const geometry =
|
||||
@@ -198,4 +199,6 @@ document.getElementById('time').addEventListener('input', function () {
|
||||
}
|
||||
});
|
||||
map.render();
|
||||
});
|
||||
};
|
||||
control.addEventListener('input', listener);
|
||||
control.addEventListener('change', listener);
|
||||
|
||||
Reference in New Issue
Block a user