dexie-cloud-addon 4.0.0-beta.23 → 4.0.0-beta.24

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.
@@ -101,7 +101,7 @@ function __spreadArray$1(to, from, pack) {
101
101
  *
102
102
  * ==========================================================================
103
103
  *
104
- * Version 4.0.0-beta.23, Mon Oct 17 2022
104
+ * Version 4.0.0-beta.24, Mon Oct 17 2022
105
105
  *
106
106
  * https://dexie.org
107
107
  *
@@ -6436,13 +6436,26 @@ var LoginGui = /** @class */ (function (_super_1) {
6436
6436
  return LoginGui;
6437
6437
  }(d$1));
6438
6438
  function setupDefaultGUI(db) {
6439
- var el = document.createElement('div');
6440
- document.body.appendChild(el);
6441
- P(h(LoginGui, { db: db.vip }), el);
6442
6439
  var closed = false;
6440
+ var el = document.createElement('div');
6441
+ if (document.body) {
6442
+ document.body.appendChild(el);
6443
+ P(h(LoginGui, { db: db.vip }), el);
6444
+ }
6445
+ else {
6446
+ addEventListener('DOMContentLoaded', function () {
6447
+ if (!closed) {
6448
+ document.body.appendChild(el);
6449
+ P(h(LoginGui, { db: db.vip }), el);
6450
+ }
6451
+ });
6452
+ }
6443
6453
  return {
6444
6454
  unsubscribe: function () {
6445
- el.remove();
6455
+ try {
6456
+ el.remove();
6457
+ }
6458
+ catch (_a) { }
6446
6459
  closed = true;
6447
6460
  },
6448
6461
  get closed() {
@@ -6902,7 +6915,7 @@ function dexieCloud(dexie) {
6902
6915
  currentUserEmitter.next(UNAUTHORIZED_USER);
6903
6916
  });
6904
6917
  dexie.cloud = {
6905
- version: '4.0.0-beta.23',
6918
+ version: '4.0.0-beta.24',
6906
6919
  options: Object.assign({}, DEFAULT_OPTIONS),
6907
6920
  schema: null,
6908
6921
  get currentUserId() {
@@ -7233,7 +7246,7 @@ function dexieCloud(dexie) {
7233
7246
  });
7234
7247
  }
7235
7248
  }
7236
- dexieCloud.version = '4.0.0-beta.23';
7249
+ dexieCloud.version = '4.0.0-beta.24';
7237
7250
  Dexie.Cloud = dexieCloud;
7238
7251
 
7239
7252
  export { dexieCloud as default, dexieCloud, getTiedObjectId, getTiedRealmId };