dexie-cloud-addon 4.1.0-beta.46 → 4.1.0-beta.47

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.
@@ -0,0 +1,2 @@
1
+ import Dexie from "dexie";
2
+ export declare function dbOnClosed(db: Dexie, handler: () => void): () => void;
@@ -1,5 +1,5 @@
1
1
  /* ==========================================================================
2
- * dexie-cloud-addom.js
2
+ * dexie-cloud-addon.js
3
3
  * ==========================================================================
4
4
  *
5
5
  * Dexie addon that syncs IndexedDB with Dexie Cloud.
@@ -8,7 +8,7 @@
8
8
  *
9
9
  * ==========================================================================
10
10
  *
11
- * Version 4.1.0-beta.46, Thu Apr 03 2025
11
+ * Version 4.1.0-beta.47, Mon May 12 2025
12
12
  *
13
13
  * https://dexie.org
14
14
  *
@@ -1803,10 +1803,11 @@
1803
1803
  }
1804
1804
  }
1805
1805
 
1806
- const hasArrayBufferB64 = "fromBase64" in Uint8Array; // https://github.com/tc39/proposal-arraybuffer-base64;
1806
+ const hasArrayBufferFromBase64 = "fromBase64" in Uint8Array; // https://github.com/tc39/proposal-arraybuffer-base64;
1807
+ const hasArrayBufferToBase64 = "toBase64" in Uint8Array.prototype; // https://github.com/tc39/proposal-arraybuffer-base64;
1807
1808
  const b64decode = typeof Buffer !== "undefined"
1808
1809
  ? (base64) => Buffer.from(base64, "base64") // Node
1809
- : hasArrayBufferB64
1810
+ : hasArrayBufferFromBase64
1810
1811
  ? // @ts-ignore: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Uint8Array/fromBase64
1811
1812
  (base64) => Uint8Array.fromBase64(base64) // Modern javascript standard
1812
1813
  : (base64) => {
@@ -1829,7 +1830,7 @@
1829
1830
  return Buffer.from(b).toString("base64");
1830
1831
  }
1831
1832
  }
1832
- : hasArrayBufferB64
1833
+ : hasArrayBufferToBase64
1833
1834
  ? // @ts-ignore https://github.com/tc39/proposal-arraybuffer-base64
1834
1835
  (b) => b.toBase64() // Modern Javascript standard
1835
1836
  : (b) => {
@@ -3567,6 +3568,7 @@
3567
3568
  accessTokenExpiration: refreshedLogin.accessTokenExpiration,
3568
3569
  claims: refreshedLogin.claims,
3569
3570
  license: refreshedLogin.license,
3571
+ data: refreshedLogin.data,
3570
3572
  });
3571
3573
  return refreshedLogin;
3572
3574
  });
@@ -8276,7 +8278,7 @@
8276
8278
  const syncComplete = new rxjs.Subject();
8277
8279
  dexie.cloud = {
8278
8280
  // @ts-ignore
8279
- version: "4.1.0-beta.46",
8281
+ version: "4.1.0-beta.47",
8280
8282
  options: Object.assign({}, DEFAULT_OPTIONS),
8281
8283
  schema: null,
8282
8284
  get currentUserId() {
@@ -8594,7 +8596,7 @@
8594
8596
  }
8595
8597
  }
8596
8598
  // @ts-ignore
8597
- dexieCloud.version = "4.1.0-beta.46";
8599
+ dexieCloud.version = "4.1.0-beta.47";
8598
8600
  Dexie.Cloud = dexieCloud;
8599
8601
 
8600
8602
  // In case the SW lives for a while, let it reuse already opened connections: