@fluxstack/live-client 0.6.0 → 0.7.0

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.
@@ -451,15 +451,27 @@ var FluxstackLive = (() => {
451
451
  return v !== null && typeof v === "object" && !Array.isArray(v) && Object.getPrototypeOf(v) === Object.prototype;
452
452
  }
453
453
  function deepMerge(target, source, seen) {
454
+ return deepMergeImpl(target, source, 0, seen);
455
+ }
456
+ function deepMergeImpl(target, source, depth, seen) {
454
457
  if (!seen) seen = /* @__PURE__ */ new Set();
455
458
  if (seen.has(source)) return target;
456
459
  seen.add(source);
457
460
  const result = { ...target };
458
461
  for (const key of Object.keys(source)) {
459
462
  const newVal = source[key];
463
+ if (newVal === void 0) continue;
464
+ if (newVal === null) {
465
+ if (depth === 0) {
466
+ result[key] = null;
467
+ } else {
468
+ delete result[key];
469
+ }
470
+ continue;
471
+ }
460
472
  const oldVal = result[key];
461
473
  if (isPlainObject(oldVal) && isPlainObject(newVal)) {
462
- result[key] = deepMerge(oldVal, newVal, seen);
474
+ result[key] = deepMergeImpl(oldVal, newVal, depth + 1, seen);
463
475
  } else {
464
476
  result[key] = newVal;
465
477
  }
@@ -731,15 +743,27 @@ var FluxstackLive = (() => {
731
743
  return v !== null && typeof v === "object" && !Array.isArray(v) && Object.getPrototypeOf(v) === Object.prototype;
732
744
  }
733
745
  function deepMerge2(target, source, seen) {
746
+ return deepMergeImpl2(target, source, 0, seen);
747
+ }
748
+ function deepMergeImpl2(target, source, depth, seen) {
734
749
  if (!seen) seen = /* @__PURE__ */ new Set();
735
750
  if (seen.has(source)) return target;
736
751
  seen.add(source);
737
752
  const result = { ...target };
738
753
  for (const key of Object.keys(source)) {
739
754
  const newVal = source[key];
755
+ if (newVal === void 0) continue;
756
+ if (newVal === null) {
757
+ if (depth === 0) {
758
+ result[key] = null;
759
+ } else {
760
+ delete result[key];
761
+ }
762
+ continue;
763
+ }
740
764
  const oldVal = result[key];
741
765
  if (isPlainObject2(oldVal) && isPlainObject2(newVal)) {
742
- result[key] = deepMerge2(oldVal, newVal, seen);
766
+ result[key] = deepMergeImpl2(oldVal, newVal, depth + 1, seen);
743
767
  } else {
744
768
  result[key] = newVal;
745
769
  }
@@ -1271,7 +1295,7 @@ var FluxstackLive = (() => {
1271
1295
  }
1272
1296
  var ChunkedUploader = class {
1273
1297
  constructor(componentId, options) {
1274
- this.componentId = componentId;
1298
+ __publicField(this, "componentId", componentId);
1275
1299
  __publicField(this, "options");
1276
1300
  __publicField(this, "abortController", null);
1277
1301
  __publicField(this, "adaptiveSizer", null);