@rpgjs/vite 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/CHANGELOG.md ADDED
@@ -0,0 +1,12 @@
1
+ # @rpgjs/vite
2
+
3
+ ## 5.0.0-beta.8
4
+
5
+ ### Major Changes
6
+
7
+ - 35e7fa4: beta.8
8
+
9
+ ### Patch Changes
10
+
11
+ - Updated dependencies [35e7fa4]
12
+ - @rpgjs/server@5.0.0-beta.8
package/dist/index.js CHANGED
@@ -6801,7 +6801,7 @@ function replaceConfigImport() {
6801
6801
  };
6802
6802
  }
6803
6803
  //#endregion
6804
- //#region ../server/dist/module-5HOX9Ovu.js
6804
+ //#region ../server/dist/module-BrK6VWLE.js
6805
6805
  /******************************************************************************
6806
6806
  Copyright (c) Microsoft Corporation.
6807
6807
 
@@ -8027,6 +8027,8 @@ function map(project, thisArg) {
8027
8027
  }));
8028
8028
  });
8029
8029
  }
8030
+ Array.isArray;
8031
+ Array.isArray;
8030
8032
  function mergeInternals(source, subscriber, project, concurrent, onBeforeNext, expand, innerSubScheduler, additionalFinalizer) {
8031
8033
  var buffer = [];
8032
8034
  var active = 0;
@@ -8277,8 +8279,8 @@ var getGlobalReactiveStore = () => {
8277
8279
  }
8278
8280
  let globalObj;
8279
8281
  if (typeof window !== "undefined") globalObj = window;
8282
+ else if (typeof process !== "undefined" && process.versions && process.versions.node) globalObj = Function("return this")();
8280
8283
  else if (typeof self !== "undefined") globalObj = self;
8281
- else if (typeof Function !== "undefined") globalObj = Function("return this")();
8282
8284
  else {
8283
8285
  console.warn("Unable to find global object, using local instance");
8284
8286
  return {
@@ -8748,6 +8750,9 @@ var RpgCommonPlayer = class {
8748
8750
  getDirection() {
8749
8751
  return this.direction();
8750
8752
  }
8753
+ isEvent() {
8754
+ return false;
8755
+ }
8751
8756
  };
8752
8757
  __decorate([id(), __decorateMetadata("design:type", String)], RpgCommonPlayer.prototype, "id", void 0);
8753
8758
  __decorate([sync(), __decorateMetadata("design:type", Object)], RpgCommonPlayer.prototype, "name", void 0);
@@ -9422,8 +9427,17 @@ function getTiledBasePaths(paths) {
9422
9427
  function resolveMapUpdateToken(explicitToken) {
9423
9428
  return explicitToken ?? readEnvVariable$1("RPGJS_MAP_UPDATE_TOKEN") ?? "";
9424
9429
  }
9430
+ function normalizeMapUpdateHeaders(init) {
9431
+ if (!init) return void 0;
9432
+ if (init instanceof Headers || Array.isArray(init)) return init;
9433
+ if (init instanceof Map) return Array.from(init.entries()).filter((entry) => entry[1] !== void 0);
9434
+ return Object.entries(init).flatMap(([key, value]) => {
9435
+ if (value === void 0) return [];
9436
+ return Array.isArray(value) ? value.map((item) => [key, item]) : [[key, value]];
9437
+ });
9438
+ }
9425
9439
  function createMapUpdateHeaders(token, init) {
9426
- const headers = new Headers(init);
9440
+ const headers = new Headers(normalizeMapUpdateHeaders(init));
9427
9441
  if (!headers.has("content-type")) headers.set("content-type", "application/json");
9428
9442
  const resolvedToken = resolveMapUpdateToken(token);
9429
9443
  if (resolvedToken) headers.set(MAP_UPDATE_TOKEN_HEADER, resolvedToken);