dexie-cloud-addon 4.0.1 → 4.0.3
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.
- package/dist/modern/db/entities/UserLogin.d.ts +1 -0
- package/dist/modern/dexie-cloud-addon.js +24 -8
- package/dist/modern/dexie-cloud-addon.js.map +1 -1
- package/dist/modern/dexie-cloud-addon.min.js +1 -1
- package/dist/modern/dexie-cloud-addon.min.js.map +1 -1
- package/dist/modern/service-worker.js +24 -8
- package/dist/modern/service-worker.js.map +1 -1
- package/dist/modern/service-worker.min.js +1 -1
- package/dist/modern/service-worker.min.js.map +1 -1
- package/dist/umd/db/entities/UserLogin.d.ts +1 -0
- package/dist/umd/dexie-cloud-addon.js +24 -8
- package/dist/umd/dexie-cloud-addon.js.map +1 -1
- package/dist/umd/dexie-cloud-addon.min.js +1 -1
- package/dist/umd/dexie-cloud-addon.min.js.map +1 -1
- package/dist/umd/service-worker.js +24 -8
- package/dist/umd/service-worker.js.map +1 -1
- package/dist/umd/service-worker.min.js +1 -1
- package/dist/umd/service-worker.min.js.map +1 -1
- package/package.json +1 -1
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
*
|
|
9
9
|
* ==========================================================================
|
|
10
10
|
*
|
|
11
|
-
* Version 4.0.
|
|
11
|
+
* Version 4.0.3, Sat Apr 13 2024
|
|
12
12
|
*
|
|
13
13
|
* https://dexie.org
|
|
14
14
|
*
|
|
@@ -2540,6 +2540,9 @@
|
|
|
2540
2540
|
if (response.userValidUntil != null) {
|
|
2541
2541
|
login.license.validUntil = new Date(response.userValidUntil);
|
|
2542
2542
|
}
|
|
2543
|
+
if (response.data) {
|
|
2544
|
+
login.data = response.data;
|
|
2545
|
+
}
|
|
2543
2546
|
return login;
|
|
2544
2547
|
});
|
|
2545
2548
|
}
|
|
@@ -2594,6 +2597,7 @@
|
|
|
2594
2597
|
type: response2.userType,
|
|
2595
2598
|
status: response2.claims.license || 'ok',
|
|
2596
2599
|
};
|
|
2600
|
+
context.data = response2.data;
|
|
2597
2601
|
if (response2.evalDaysLeft != null) {
|
|
2598
2602
|
context.license.evalDaysLeft = response2.evalDaysLeft;
|
|
2599
2603
|
}
|
|
@@ -3922,6 +3926,7 @@
|
|
|
3922
3926
|
accessTokenExpiration: refreshedLogin.accessTokenExpiration,
|
|
3923
3927
|
claims: refreshedLogin.claims,
|
|
3924
3928
|
license: refreshedLogin.license,
|
|
3929
|
+
data: refreshedLogin.data,
|
|
3925
3930
|
});
|
|
3926
3931
|
// Updating $logins will trigger emission of db.cloud.currentUser observable, which
|
|
3927
3932
|
// in turn will lead to that connectWebSocket.ts will reconnect the socket with the
|
|
@@ -4280,11 +4285,21 @@
|
|
|
4280
4285
|
}
|
|
4281
4286
|
else {
|
|
4282
4287
|
const email = yield promptForEmail(userInteraction, 'Enter email address', hints === null || hints === void 0 ? void 0 : hints.email);
|
|
4283
|
-
|
|
4284
|
-
|
|
4285
|
-
|
|
4286
|
-
|
|
4287
|
-
|
|
4288
|
+
if (/@demo.local$/.test(email)) {
|
|
4289
|
+
tokenRequest = {
|
|
4290
|
+
demo_user: email,
|
|
4291
|
+
grant_type: 'demo',
|
|
4292
|
+
scopes: ['ACCESS_DB'],
|
|
4293
|
+
public_key
|
|
4294
|
+
};
|
|
4295
|
+
}
|
|
4296
|
+
else {
|
|
4297
|
+
tokenRequest = {
|
|
4298
|
+
email,
|
|
4299
|
+
grant_type: 'otp',
|
|
4300
|
+
scopes: ['ACCESS_DB'],
|
|
4301
|
+
};
|
|
4302
|
+
}
|
|
4288
4303
|
}
|
|
4289
4304
|
const res1 = yield fetch(`${url}/token`, {
|
|
4290
4305
|
body: JSON.stringify(tokenRequest),
|
|
@@ -5460,6 +5475,7 @@
|
|
|
5460
5475
|
accessTokenExpiration: refreshedLogin.accessTokenExpiration,
|
|
5461
5476
|
claims: refreshedLogin.claims,
|
|
5462
5477
|
license: refreshedLogin.license,
|
|
5478
|
+
data: refreshedLogin.data
|
|
5463
5479
|
});
|
|
5464
5480
|
})), switchMap(() => createObservable()));
|
|
5465
5481
|
}
|
|
@@ -6286,7 +6302,7 @@
|
|
|
6286
6302
|
const syncComplete = new rxjs.Subject();
|
|
6287
6303
|
dexie.cloud = {
|
|
6288
6304
|
// @ts-ignore
|
|
6289
|
-
version: "4.0.
|
|
6305
|
+
version: "4.0.3",
|
|
6290
6306
|
options: Object.assign({}, DEFAULT_OPTIONS),
|
|
6291
6307
|
schema: null,
|
|
6292
6308
|
get currentUserId() {
|
|
@@ -6563,7 +6579,7 @@
|
|
|
6563
6579
|
}
|
|
6564
6580
|
}
|
|
6565
6581
|
// @ts-ignore
|
|
6566
|
-
dexieCloud.version = "4.0.
|
|
6582
|
+
dexieCloud.version = "4.0.3";
|
|
6567
6583
|
Dexie.Cloud = dexieCloud;
|
|
6568
6584
|
|
|
6569
6585
|
// In case the SW lives for a while, let it reuse already opened connections:
|