@cocreate/users 1.22.3 → 1.22.5

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/CHANGELOG.md CHANGED
@@ -1,3 +1,17 @@
1
+ ## [1.22.5](https://github.com/CoCreate-app/CoCreate-users/compare/v1.22.4...v1.22.5) (2023-05-23)
2
+
3
+
4
+ ### Bug Fixes
5
+
6
+ * Add indexedDB support and remove db property when signing in. ([7979c19](https://github.com/CoCreate-app/CoCreate-users/commit/7979c192bd21905437aa65893b7a9600793e7fbc))
7
+
8
+ ## [1.22.4](https://github.com/CoCreate-app/CoCreate-users/compare/v1.22.3...v1.22.4) (2023-05-21)
9
+
10
+
11
+ ### Bug Fixes
12
+
13
+ * Add UID to sign-in and user status response ([33801a9](https://github.com/CoCreate-app/CoCreate-users/commit/33801a93dc5c2a36d3752dbe39abf443b8cc884c))
14
+
1
15
  ## [1.22.3](https://github.com/CoCreate-app/CoCreate-users/compare/v1.22.2...v1.22.3) (2023-05-21)
2
16
 
3
17
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cocreate/users",
3
- "version": "1.22.3",
3
+ "version": "1.22.5",
4
4
  "description": "A simple users component in vanilla javascript. Easily configured using HTML5 attributes and/or JavaScript API.",
5
5
  "keywords": [
6
6
  "users",
@@ -59,12 +59,12 @@
59
59
  "webpack-log": "^3.0.1"
60
60
  },
61
61
  "dependencies": {
62
- "@cocreate/actions": "^1.8.11",
63
- "@cocreate/crud-client": "^1.21.4",
64
- "@cocreate/docs": "^1.7.12",
65
- "@cocreate/element-prototype": "^1.8.11",
66
- "@cocreate/form": "^1.14.11",
67
- "@cocreate/local-storage": "^1.7.2",
68
- "@cocreate/render": "^1.24.12"
62
+ "@cocreate/actions": "^1.8.12",
63
+ "@cocreate/crud-client": "^1.21.5",
64
+ "@cocreate/docs": "^1.7.13",
65
+ "@cocreate/element-prototype": "^1.8.12",
66
+ "@cocreate/form": "^1.14.12",
67
+ "@cocreate/local-storage": "^1.7.3",
68
+ "@cocreate/render": "^1.24.13"
69
69
  }
70
70
  }
package/src/client.js CHANGED
@@ -94,6 +94,7 @@ const CoCreateUser = {
94
94
  });
95
95
 
96
96
  let request = {
97
+ db: 'indexeddb',
97
98
  collection,
98
99
  // document: {
99
100
  // lastSignIn: new Date().toISOString()
@@ -119,6 +120,7 @@ const CoCreateUser = {
119
120
  })
120
121
  } else {
121
122
  request.broadcastBrowser = false
123
+ delete request.db
122
124
  crud.socket.send('signIn', request).then((response) => {
123
125
  this.signInResponse(response)
124
126
  })
package/src/server.js CHANGED
@@ -53,7 +53,8 @@ class CoCreateUser {
53
53
  success: false,
54
54
  message: "signIn failed",
55
55
  status: "failed",
56
- userStatus: 'off'
56
+ userStatus: 'off',
57
+ uid: data.uid
57
58
  }
58
59
 
59
60
  if (data.document[0] && data.document[0]._id && self.wsManager.authInstance) {
@@ -67,7 +68,8 @@ class CoCreateUser {
67
68
  status: "success",
68
69
  userStatus: 'on',
69
70
  user_id,
70
- token
71
+ token,
72
+ uid: data.uid
71
73
  };
72
74
 
73
75
  // if (data.organization_id != process.env.organization_id) {