@loaders.gl/core 4.1.3 → 4.1.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/dist.dev.js CHANGED
@@ -136,7 +136,7 @@ var __exports__ = (() => {
136
136
  console.warn("loaders.gl: The __VERSION__ variable is not injected using babel plugin. Latest unstable workers would be fetched from the CDN.");
137
137
  globalThis._loadersgl_.version = NPM_TAG;
138
138
  } else {
139
- globalThis._loadersgl_.version = "4.1.3";
139
+ globalThis._loadersgl_.version = "4.1.4";
140
140
  }
141
141
  }
142
142
  return globalThis._loadersgl_.version;
@@ -1102,13 +1102,14 @@ var __exports__ = (() => {
1102
1102
  var DEFAULT_PROPS2 = {
1103
1103
  id: "request-scheduler",
1104
1104
  throttleRequests: true,
1105
- maxRequests: 6
1105
+ maxRequests: 6,
1106
+ debounceTime: 0
1106
1107
  };
1107
1108
  var RequestScheduler = class {
1108
1109
  activeRequestCount = 0;
1109
1110
  requestQueue = [];
1110
1111
  requestMap = /* @__PURE__ */ new Map();
1111
- deferredUpdate = null;
1112
+ updateTimer = null;
1112
1113
  constructor(props = {}) {
1113
1114
  this.props = {
1114
1115
  ...DEFAULT_PROPS2,
@@ -1169,12 +1170,16 @@ var __exports__ = (() => {
1169
1170
  });
1170
1171
  }
1171
1172
  _issueNewRequests() {
1172
- if (!this.deferredUpdate) {
1173
- this.deferredUpdate = setTimeout(() => this._issueNewRequestsAsync(), 0);
1173
+ if (this.updateTimer !== null) {
1174
+ clearTimeout(this.updateTimer);
1174
1175
  }
1176
+ this.updateTimer = setTimeout(() => this._issueNewRequestsAsync(), this.props.debounceTime);
1175
1177
  }
1176
1178
  _issueNewRequestsAsync() {
1177
- this.deferredUpdate = null;
1179
+ if (this.updateTimer !== null) {
1180
+ clearTimeout(this.updateTimer);
1181
+ }
1182
+ this.updateTimer = null;
1178
1183
  const freeSlots = Math.max(this.props.maxRequests - this.activeRequestCount, 0);
1179
1184
  if (freeSlots === 0) {
1180
1185
  return;
@@ -1232,7 +1237,7 @@ var __exports__ = (() => {
1232
1237
  }
1233
1238
 
1234
1239
  // ../loader-utils/src/json-loader.ts
1235
- var VERSION2 = true ? "4.1.3" : "latest";
1240
+ var VERSION2 = true ? "4.1.4" : "latest";
1236
1241
  var JSONLoader = {
1237
1242
  name: "JSON",
1238
1243
  id: "json",
@@ -3349,7 +3354,7 @@ var __exports__ = (() => {
3349
3354
  }
3350
3355
 
3351
3356
  // src/null-loader.ts
3352
- var VERSION4 = true ? "4.1.3" : "latest";
3357
+ var VERSION4 = true ? "4.1.4" : "latest";
3353
3358
  var NullWorkerLoader = {
3354
3359
  name: "Null loader",
3355
3360
  id: "null",
package/dist/lib/init.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { log } from "./utils/log.js";
2
- const version = typeof "4.1.3" !== 'undefined' ? "4.1.3" : '';
2
+ const version = typeof "4.1.4" !== 'undefined' ? "4.1.4" : '';
3
3
  if (!globalThis.loaders) {
4
4
  log.log(1, `loaders.gl ${version}`)();
5
5
  globalThis.loaders = Object.assign(globalThis.loaders || {}, {
@@ -1,4 +1,4 @@
1
- const VERSION = typeof "4.1.3" !== 'undefined' ? "4.1.3" : 'latest';
1
+ const VERSION = typeof "4.1.4" !== 'undefined' ? "4.1.4" : 'latest';
2
2
  export const NullWorkerLoader = {
3
3
  name: 'Null loader',
4
4
  id: 'null',
@@ -233,7 +233,7 @@ async function parseData({
233
233
  }
234
234
 
235
235
  // src/null-loader.ts
236
- var VERSION = true ? "4.1.3" : "latest";
236
+ var VERSION = true ? "4.1.4" : "latest";
237
237
  var NullLoader = {
238
238
  name: "Null loader",
239
239
  id: "null",
@@ -198,7 +198,7 @@
198
198
  }
199
199
 
200
200
  // src/null-loader.ts
201
- var VERSION = true ? "4.1.3" : "latest";
201
+ var VERSION = true ? "4.1.4" : "latest";
202
202
  var NullLoader = {
203
203
  name: "Null loader",
204
204
  id: "null",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@loaders.gl/core",
3
- "version": "4.1.3",
3
+ "version": "4.1.4",
4
4
  "description": "The core API for working with loaders.gl loaders and writers",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -55,9 +55,9 @@
55
55
  },
56
56
  "dependencies": {
57
57
  "@babel/runtime": "^7.3.1",
58
- "@loaders.gl/loader-utils": "4.1.3",
59
- "@loaders.gl/worker-utils": "4.1.3",
58
+ "@loaders.gl/loader-utils": "4.1.4",
59
+ "@loaders.gl/worker-utils": "4.1.4",
60
60
  "@probe.gl/log": "^4.0.2"
61
61
  },
62
- "gitHead": "4313c1f68c25723ab3e906db5a6ac65c2e8ac7b6"
62
+ "gitHead": "e5b4fe1845c1483addfc4c3d630f1617595efbae"
63
63
  }