@loaders.gl/splats 5.0.0-beta.7 → 5.0.0-beta.8

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
@@ -794,7 +794,13 @@ var __exports__ = (() => {
794
794
  globalThis.probe.loaders = log3;
795
795
  return log3;
796
796
  }
797
- var VERSION2, version, log2;
797
+ function ignoreMessage() {
798
+ }
799
+ function getLoaderLog(options) {
800
+ const logger = options?.core?.log !== void 0 ? options.core.log : options?.log;
801
+ return logger === null ? nullLog : logger || log2;
802
+ }
803
+ var VERSION2, version, log2, NullLog, nullLog;
798
804
  var init_log2 = __esm({
799
805
  "../core/src/loader-utils/lib/log-utils/log.ts"() {
800
806
  "use strict";
@@ -802,6 +808,29 @@ var __exports__ = (() => {
802
808
  VERSION2 = typeof __VERSION__ !== "undefined" ? __VERSION__ : "latest";
803
809
  version = VERSION2[0] >= "0" && VERSION2[0] <= "9" ? `v${VERSION2}` : "";
804
810
  log2 = createLog();
811
+ NullLog = class {
812
+ /** Discards debug messages. */
813
+ log() {
814
+ return ignoreMessage;
815
+ }
816
+ /** Discards informational messages. */
817
+ info() {
818
+ return ignoreMessage;
819
+ }
820
+ /** Discards messages marked to be emitted once. */
821
+ once() {
822
+ return ignoreMessage;
823
+ }
824
+ /** Discards warnings. */
825
+ warn() {
826
+ return ignoreMessage;
827
+ }
828
+ /** Discards errors. */
829
+ error() {
830
+ return ignoreMessage;
831
+ }
832
+ };
833
+ nullLog = new NullLog();
805
834
  }
806
835
  });
807
836
 
@@ -1249,7 +1278,7 @@ var __exports__ = (() => {
1249
1278
  function unavailableCoreApiMethod(methodName) {
1250
1279
  return () => {
1251
1280
  throw new Error(
1252
- `CoreAPI.${methodName} is unavailable. Use @loaders.gl/core.createDataSource().`
1281
+ `CoreAPI.${methodName} is unavailable. Use @loaders.gl/core.createDataSourceSync().`
1253
1282
  );
1254
1283
  };
1255
1284
  }
@@ -1379,7 +1408,7 @@ var __exports__ = (() => {
1379
1408
  if (callback) {
1380
1409
  callback(normalizedError, this);
1381
1410
  } else {
1382
- log2.warn(`${this.constructor.name}: ${normalizedError.message}`)();
1411
+ getLoaderLog(this.options).warn(`${this.constructor.name}: ${normalizedError.message}`)();
1383
1412
  }
1384
1413
  return normalizedError;
1385
1414
  }
@@ -39123,6 +39152,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
39123
39152
  concatenateArrayBuffersAsync: () => import_core9.concatenateArrayBuffersAsync,
39124
39153
  coreApi: () => import_core9.coreApi,
39125
39154
  createDataSource: () => import_core9.createDataSource,
39155
+ createDataSourceSync: () => import_core9.createDataSourceSync,
39126
39156
  document: () => import_core9.document,
39127
39157
  encode: () => import_core9.encode,
39128
39158
  encodeInBatches: () => import_core9.encodeInBatches,
@@ -39218,7 +39248,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
39218
39248
  }
39219
39249
  },
39220
39250
  testURL: (url2) => /\.rad(?:$|[?#])/i.test(url2),
39221
- createDataSource: (data, options, coreApi2) => new RADSource(data, options, coreApi2)
39251
+ createDataSourceSync: (data, options, coreApi2) => new RADSource(data, options, coreApi2)
39222
39252
  };
39223
39253
  var RADSource = class extends DataSource {
39224
39254
  /** Shared metadata promise exposed for source-style integrations. */