@affectively/aeon 1.2.0 → 1.3.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.
Files changed (43) hide show
  1. package/dist/compression/index.cjs.map +1 -1
  2. package/dist/compression/index.js.map +1 -1
  3. package/dist/core/index.d.cts +105 -100
  4. package/dist/core/index.d.ts +105 -100
  5. package/dist/crypto/index.cjs.map +1 -1
  6. package/dist/crypto/index.d.cts +310 -271
  7. package/dist/crypto/index.d.ts +310 -271
  8. package/dist/crypto/index.js.map +1 -1
  9. package/dist/distributed/index.cjs +8 -2
  10. package/dist/distributed/index.cjs.map +1 -1
  11. package/dist/distributed/index.d.cts +871 -756
  12. package/dist/distributed/index.d.ts +871 -756
  13. package/dist/distributed/index.js +8 -2
  14. package/dist/distributed/index.js.map +1 -1
  15. package/dist/index.cjs +26 -10
  16. package/dist/index.cjs.map +1 -1
  17. package/dist/index.d.cts +1 -1
  18. package/dist/index.d.ts +1 -1
  19. package/dist/index.js +26 -10
  20. package/dist/index.js.map +1 -1
  21. package/dist/offline/index.cjs.map +1 -1
  22. package/dist/offline/index.d.cts +128 -122
  23. package/dist/offline/index.d.ts +128 -122
  24. package/dist/offline/index.js.map +1 -1
  25. package/dist/optimization/index.cjs.map +1 -1
  26. package/dist/optimization/index.js.map +1 -1
  27. package/dist/persistence/index.cjs.map +1 -1
  28. package/dist/persistence/index.d.cts +38 -38
  29. package/dist/persistence/index.d.ts +38 -38
  30. package/dist/persistence/index.js.map +1 -1
  31. package/dist/presence/index.cjs.map +1 -1
  32. package/dist/presence/index.js.map +1 -1
  33. package/dist/{types-CMxO7QF0.d.cts → types-B7gCpNX9.d.cts} +6 -6
  34. package/dist/{types-CMxO7QF0.d.ts → types-B7gCpNX9.d.ts} +6 -6
  35. package/dist/utils/index.d.cts +4 -4
  36. package/dist/utils/index.d.ts +4 -4
  37. package/dist/versioning/index.cjs +18 -8
  38. package/dist/versioning/index.cjs.map +1 -1
  39. package/dist/versioning/index.d.cts +1 -1
  40. package/dist/versioning/index.d.ts +1 -1
  41. package/dist/versioning/index.js +18 -8
  42. package/dist/versioning/index.js.map +1 -1
  43. package/package.json +6 -2
package/dist/index.cjs CHANGED
@@ -1088,11 +1088,13 @@ var MigrationTracker = class _MigrationTracker {
1088
1088
  });
1089
1089
  previousHash = hash;
1090
1090
  }
1091
- const persistedMigrations = normalizedMigrations.map((migration, index) => ({
1092
- ...migration,
1093
- previousHash: integrityEntries[index]?.previousHash,
1094
- integrityHash: integrityEntries[index]?.hash
1095
- }));
1091
+ const persistedMigrations = normalizedMigrations.map(
1092
+ (migration, index) => ({
1093
+ ...migration,
1094
+ previousHash: integrityEntries[index]?.previousHash,
1095
+ integrityHash: integrityEntries[index]?.hash
1096
+ })
1097
+ );
1096
1098
  const data = {
1097
1099
  migrations: persistedMigrations,
1098
1100
  snapshots: Array.from(this.snapshots.entries()).map(
@@ -1115,7 +1117,10 @@ var MigrationTracker = class _MigrationTracker {
1115
1117
  data
1116
1118
  };
1117
1119
  const serialize = this.persistence.serializer ?? ((value) => JSON.stringify(value));
1118
- await this.persistence.adapter.setItem(this.persistence.key, serialize(envelope));
1120
+ await this.persistence.adapter.setItem(
1121
+ this.persistence.key,
1122
+ serialize(envelope)
1123
+ );
1119
1124
  }
1120
1125
  /**
1121
1126
  * Load tracker state and verify integrity chain.
@@ -1128,7 +1133,9 @@ var MigrationTracker = class _MigrationTracker {
1128
1133
  if (!raw) {
1129
1134
  return { migrations: 0, snapshots: 0 };
1130
1135
  }
1131
- const deserialize = this.persistence.deserializer ?? ((value) => JSON.parse(value));
1136
+ const deserialize = this.persistence.deserializer ?? ((value) => JSON.parse(
1137
+ value
1138
+ ));
1132
1139
  const envelope = deserialize(raw);
1133
1140
  if (envelope.version !== 1 || !envelope.data) {
1134
1141
  throw new Error("Invalid migration tracker persistence payload");
@@ -1191,7 +1198,10 @@ var MigrationTracker = class _MigrationTracker {
1191
1198
  migrations: this.migrations.length,
1192
1199
  snapshots: this.snapshots.size
1193
1200
  });
1194
- return { migrations: this.migrations.length, snapshots: this.snapshots.size };
1201
+ return {
1202
+ migrations: this.migrations.length,
1203
+ snapshots: this.snapshots.size
1204
+ };
1195
1205
  }
1196
1206
  /**
1197
1207
  * Remove persisted migration tracker state.
@@ -2277,7 +2287,10 @@ var ReplicationManager = class _ReplicationManager {
2277
2287
  data
2278
2288
  };
2279
2289
  const serialize = this.persistence.serializer ?? ((value) => JSON.stringify(value));
2280
- await this.persistence.adapter.setItem(this.persistence.key, serialize(envelope));
2290
+ await this.persistence.adapter.setItem(
2291
+ this.persistence.key,
2292
+ serialize(envelope)
2293
+ );
2281
2294
  }
2282
2295
  /**
2283
2296
  * Load replication snapshot from persistence.
@@ -2990,7 +3003,10 @@ var SyncProtocol = class _SyncProtocol {
2990
3003
  data
2991
3004
  };
2992
3005
  const serialize = this.persistence.serializer ?? ((value) => JSON.stringify(value));
2993
- await this.persistence.adapter.setItem(this.persistence.key, serialize(envelope));
3006
+ await this.persistence.adapter.setItem(
3007
+ this.persistence.key,
3008
+ serialize(envelope)
3009
+ );
2994
3010
  }
2995
3011
  /**
2996
3012
  * Load protocol state from persistence.