@pixerate/editor 0.140.0 → 0.140.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.
Files changed (59) hide show
  1. package/dist/agent/index.cjs +39 -31
  2. package/dist/agent/index.js +13 -5
  3. package/dist/bridge/cli.cjs +4 -3
  4. package/dist/bridge/cli.js +3 -2
  5. package/dist/bridge/index.cjs +4 -3
  6. package/dist/bridge/index.js +3 -2
  7. package/dist/chunk-2BSBFBOA.cjs +46 -0
  8. package/dist/{chunk-SWZTQWY7.js → chunk-2INPJDNY.js} +1 -1
  9. package/dist/{chunk-CCKP4XAN.cjs → chunk-34RQAGWI.cjs} +27 -7
  10. package/dist/{chunk-HXCBQ7A6.cjs → chunk-3AJMR7EG.cjs} +7 -4
  11. package/dist/{chunk-NKBUVQJW.cjs → chunk-5WOY52O6.cjs} +15 -15
  12. package/dist/{chunk-5G3KYRER.js → chunk-6GAYGQDC.js} +8 -7
  13. package/dist/{chunk-HZZXBTLB.js → chunk-6IN474P4.js} +25 -5
  14. package/dist/{chunk-HDCH35UM.cjs → chunk-AGCD3EHB.cjs} +7 -7
  15. package/dist/{chunk-6I63VZ45.js → chunk-CXXKJBQZ.js} +5 -1
  16. package/dist/{chunk-6NXVDJDR.cjs → chunk-G43MNQ4C.cjs} +5 -5
  17. package/dist/{chunk-ZAOOIJ6I.cjs → chunk-HDK3T2QS.cjs} +4 -1
  18. package/dist/chunk-HF5QZS7Z.js +46 -0
  19. package/dist/{chunk-S7I3RI5Z.cjs → chunk-HMGWFXEC.cjs} +27 -24
  20. package/dist/{chunk-RPW7YL3D.cjs → chunk-L434J57V.cjs} +8 -7
  21. package/dist/{chunk-UCRL6JEV.cjs → chunk-L5OWG2NA.cjs} +8 -3
  22. package/dist/{chunk-RWML7TWG.cjs → chunk-PUR6BZFA.cjs} +112 -111
  23. package/dist/{chunk-WBKLYLZE.js → chunk-RB62U6MS.js} +4 -1
  24. package/dist/{chunk-KIBEEN5K.js → chunk-UMS6YFA6.js} +1 -1
  25. package/dist/{chunk-4LGWAJDI.js → chunk-V5OOP74P.js} +5 -2
  26. package/dist/{chunk-UOJS6PUP.js → chunk-WBJ6BG4R.js} +23 -22
  27. package/dist/{chunk-WIYAOZZU.js → chunk-WHKNYFM2.js} +7 -2
  28. package/dist/{chunk-F652BKMS.cjs → chunk-YN6JKAUE.cjs} +6 -2
  29. package/dist/{chunk-YTGF4TJR.js → chunk-ZLZKGHSZ.js} +5 -2
  30. package/dist/{chunk-USU2FL3N.js → chunk-ZNHB5RG6.js} +1 -1
  31. package/dist/compare/index.cjs +4 -3
  32. package/dist/compare/index.js +3 -2
  33. package/dist/export/index.cjs +4 -3
  34. package/dist/export/index.js +3 -2
  35. package/dist/extensions/index.cjs +11 -8
  36. package/dist/extensions/index.d.cts +1 -0
  37. package/dist/extensions/index.d.ts +1 -0
  38. package/dist/extensions/index.js +10 -7
  39. package/dist/extensions/safe-merge-attributes.d.cts +10 -0
  40. package/dist/extensions/safe-merge-attributes.d.ts +10 -0
  41. package/dist/image-editor/index.cjs +4 -3
  42. package/dist/image-editor/index.js +2 -1
  43. package/dist/index.cjs +42 -29
  44. package/dist/index.d.cts +1 -0
  45. package/dist/index.d.ts +1 -0
  46. package/dist/index.js +22 -9
  47. package/dist/persistence/index.cjs +3 -2
  48. package/dist/persistence/index.js +2 -1
  49. package/dist/serializers/index.cjs +5 -4
  50. package/dist/serializers/index.js +4 -3
  51. package/dist/tools/index.cjs +11 -3
  52. package/dist/tools/index.d.cts +1 -0
  53. package/dist/tools/index.d.ts +1 -0
  54. package/dist/tools/index.js +10 -2
  55. package/dist/tools/safe-json.d.cts +27 -0
  56. package/dist/tools/safe-json.d.ts +27 -0
  57. package/package.json +28 -28
  58. /package/dist/{chunk-MCTQXUXR.js → chunk-K73HMKQP.js} +0 -0
  59. /package/dist/{chunk-R6DFK5OX.cjs → chunk-LACYURUW.cjs} +0 -0
@@ -1,4 +1,9 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }// src/persistence/migrate.ts
1
+ "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }
2
+
3
+
4
+ var _chunk2BSBFBOAcjs = require('./chunk-2BSBFBOA.cjs');
5
+
6
+ // src/persistence/migrate.ts
2
7
  function hasLoadProblems(report) {
3
8
  return report.problems.length > 0 || report.readOnly !== null;
4
9
  }
@@ -23,7 +28,7 @@ function toObject(json) {
23
28
  return void 0;
24
29
  }
25
30
  }
26
- return isObject(value) ? deepClone(value) : void 0;
31
+ return isObject(value) ? _chunk2BSBFBOAcjs.stripPrototypeKeys.call(void 0, deepClone(value)) : void 0;
27
32
  }
28
33
  function migrateDocument(json, options) {
29
34
  const versionKey = _nullishCoalesce(options.versionKey, () => ( "version"));
@@ -106,7 +111,7 @@ function loadSections(doc, sections, options = {}) {
106
111
  }
107
112
  const unknown = {};
108
113
  for (const key of Object.keys(source)) {
109
- if (!(key in sections) && !ignore.has(key)) unknown[key] = source[key];
114
+ if (!(key in sections) && !ignore.has(key) && !_chunk2BSBFBOAcjs.isUnsafeJsonKey.call(void 0, key)) unknown[key] = source[key];
110
115
  }
111
116
  return { value, problems, unknown };
112
117
  }