@nicia-ai/typegraph 0.67.1 → 0.68.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 (40) hide show
  1. package/CHANGELOG.md +26 -0
  2. package/dist/backend/postgres/pglite-store.cjs +1 -1
  3. package/dist/backend/postgres/pglite-store.js +1 -1
  4. package/dist/backend/sqlite/local-store.cjs +1 -1
  5. package/dist/backend/sqlite/local-store.js +1 -1
  6. package/dist/{chunk-T3VU3YRQ.cjs → chunk-6GUBF5TF.cjs} +24 -18
  7. package/dist/chunk-6GUBF5TF.cjs.map +1 -0
  8. package/dist/{chunk-55DGFZYC.js → chunk-EJYBHBIB.js} +3 -3
  9. package/dist/{chunk-55DGFZYC.js.map → chunk-EJYBHBIB.js.map} +1 -1
  10. package/dist/{chunk-WY3IFEKV.cjs → chunk-IFTYHOEE.cjs} +13 -5
  11. package/dist/chunk-IFTYHOEE.cjs.map +1 -0
  12. package/dist/{chunk-RTPMG6LQ.js → chunk-JVKHJQ6Q.js} +13 -5
  13. package/dist/chunk-JVKHJQ6Q.js.map +1 -0
  14. package/dist/{chunk-FS2GVO2T.cjs → chunk-OBEYH22Q.cjs} +159 -159
  15. package/dist/{chunk-FS2GVO2T.cjs.map → chunk-OBEYH22Q.cjs.map} +1 -1
  16. package/dist/{chunk-7YJHUY4T.js → chunk-VUYODTHL.js} +10 -5
  17. package/dist/chunk-VUYODTHL.js.map +1 -0
  18. package/dist/graph-merge/index.cjs +540 -22
  19. package/dist/graph-merge/index.cjs.map +1 -1
  20. package/dist/graph-merge/index.d.cts +317 -9
  21. package/dist/graph-merge/index.d.ts +317 -9
  22. package/dist/graph-merge/index.js +512 -8
  23. package/dist/graph-merge/index.js.map +1 -1
  24. package/dist/index.cjs +43 -43
  25. package/dist/index.js +2 -2
  26. package/dist/interchange/index.cjs +25 -25
  27. package/dist/interchange/index.js +2 -2
  28. package/dist/{local-store-impl-GI6S4J6B.cjs → local-store-impl-INNRHDK3.cjs} +5 -5
  29. package/dist/{local-store-impl-GI6S4J6B.cjs.map → local-store-impl-INNRHDK3.cjs.map} +1 -1
  30. package/dist/{local-store-impl-CCMWTLGY.js → local-store-impl-VGC3OKCA.js} +4 -4
  31. package/dist/{local-store-impl-CCMWTLGY.js.map → local-store-impl-VGC3OKCA.js.map} +1 -1
  32. package/dist/{pglite-store-impl-HAPAJUIO.cjs → pglite-store-impl-KDS4NRMC.cjs} +5 -5
  33. package/dist/{pglite-store-impl-HAPAJUIO.cjs.map → pglite-store-impl-KDS4NRMC.cjs.map} +1 -1
  34. package/dist/{pglite-store-impl-HDLFOZWS.js → pglite-store-impl-LJDF2EUF.js} +4 -4
  35. package/dist/{pglite-store-impl-HDLFOZWS.js.map → pglite-store-impl-LJDF2EUF.js.map} +1 -1
  36. package/package.json +1 -1
  37. package/dist/chunk-7YJHUY4T.js.map +0 -1
  38. package/dist/chunk-RTPMG6LQ.js.map +0 -1
  39. package/dist/chunk-T3VU3YRQ.cjs.map +0 -1
  40. package/dist/chunk-WY3IFEKV.cjs.map +0 -1
@@ -21,6 +21,7 @@ var chunkJLSXOBLQ_cjs = require('./chunk-JLSXOBLQ.cjs');
21
21
  var chunkOZ3ZU7Q2_cjs = require('./chunk-OZ3ZU7Q2.cjs');
22
22
  var chunkBXHAPCQG_cjs = require('./chunk-BXHAPCQG.cjs');
23
23
  var chunk7XYPLAPL_cjs = require('./chunk-7XYPLAPL.cjs');
24
+ var zod = require('zod');
24
25
 
25
26
  // src/store/row-mappers.ts
26
27
  function nullToUndefined(value) {
@@ -3125,6 +3126,13 @@ async function executeNodeUpdate(ctx, input, backend, options) {
3125
3126
  { didWrite: writeResultAlwaysChanges }
3126
3127
  );
3127
3128
  }
3129
+ function validateNodePropertySubset(schema, properties, context) {
3130
+ return chunk6B3LQUYG_cjs.validateNodeProps(
3131
+ zod.z.object(schema.shape).partial(),
3132
+ properties,
3133
+ context
3134
+ );
3135
+ }
3128
3136
  function normalizeCompareAndSetExpectations(schema, kind, inputExpected) {
3129
3137
  if (Object.keys(inputExpected).length === 0) {
3130
3138
  throw new chunk7XYPLAPL_cjs.ValidationError("compareAndSet() expected must not be empty", {
@@ -3178,8 +3186,8 @@ function normalizeCompareAndSetExpectations(schema, kind, inputExpected) {
3178
3186
  }
3179
3187
  scalarExpectedInput[property] = value;
3180
3188
  }
3181
- const parsedExpected = chunk6B3LQUYG_cjs.validateNodeProps(
3182
- schema.partial(),
3189
+ const parsedExpected = validateNodePropertySubset(
3190
+ schema,
3183
3191
  scalarExpectedInput,
3184
3192
  { kind, operation: "update" }
3185
3193
  );
@@ -3255,7 +3263,7 @@ async function executeNodeSetUpdate(ctx, kind, inputPatch, candidateIds, candida
3255
3263
  }
3256
3264
  );
3257
3265
  }
3258
- const parsedPatch = chunk6B3LQUYG_cjs.validateNodeProps(schema.partial(), inputPatch, {
3266
+ const parsedPatch = validateNodePropertySubset(schema, inputPatch, {
3259
3267
  kind,
3260
3268
  operation: "update"
3261
3269
  });
@@ -4506,5 +4514,5 @@ exports.unsupportedResolvedMutationSet = unsupportedResolvedMutationSet;
4506
4514
  exports.validityEndAfterMutation = validityEndAfterMutation;
4507
4515
  exports.withAlreadyExistsTranslation = withAlreadyExistsTranslation;
4508
4516
  exports.writeResultAlwaysChanges = writeResultAlwaysChanges;
4509
- //# sourceMappingURL=chunk-WY3IFEKV.cjs.map
4510
- //# sourceMappingURL=chunk-WY3IFEKV.cjs.map
4517
+ //# sourceMappingURL=chunk-IFTYHOEE.cjs.map
4518
+ //# sourceMappingURL=chunk-IFTYHOEE.cjs.map