libpag 4.5.0 → 4.5.1

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/lib/libpag.umd.js CHANGED
@@ -3013,7 +3013,7 @@
3013
3013
  return value;
3014
3014
  };
3015
3015
  var PAGInit$1 = (() => {
3016
- var _scriptName = typeof document != "undefined" ? document.currentScript?.src : void 0;
3016
+ var _scriptName = import.meta.url;
3017
3017
  return async function(moduleArg = {}) {
3018
3018
  var moduleRtn;
3019
3019
  var Module = moduleArg;
@@ -3165,11 +3165,14 @@
3165
3165
  }
3166
3166
  var wasmBinaryFile;
3167
3167
  function findWasmBinary() {
3168
- var f = "libpag.wasm";
3169
- if (!isDataURI(f)) {
3170
- return locateFile(f);
3168
+ if (Module["locateFile"]) {
3169
+ var f = "libpag.wasm";
3170
+ if (!isDataURI(f)) {
3171
+ return locateFile(f);
3172
+ }
3173
+ return f;
3171
3174
  }
3172
- return f;
3175
+ return new URL("libpag.wasm", import.meta.url).href;
3173
3176
  }
3174
3177
  function getBinarySync(file) {
3175
3178
  if (file == wasmBinaryFile && wasmBinary) {