@mindline/sync 1.0.78 → 1.0.81

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.
@@ -2,5 +2,6 @@
2
2
  "ExpandedNodes": [
3
3
  ""
4
4
  ],
5
+ "SelectedNode": "\\package.json",
5
6
  "PreviewInSolutionExplorer": false
6
7
  }
package/.vs/slnx.sqlite CHANGED
Binary file
Binary file
@@ -3,21 +3,29 @@
3
3
  "WorkspaceRootPath": "C:\\Users\\ArvindSuthar\\source\\repos\\front\\sync\\",
4
4
  "Documents": [
5
5
  {
6
- "AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Users\\ArvindSuthar\\source\\repos\\front\\sync\\index.d.ts||{0F2454B1-A556-402D-A7D0-1FDE7F99DEE0}",
7
- "RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:index.d.ts||{0F2454B1-A556-402D-A7D0-1FDE7F99DEE0}"
6
+ "AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Users\\ArvindSuthar\\source\\repos\\front\\sync\\package.json||{90A6B3A7-C1A3-4009-A288-E2FF89E96FA0}",
7
+ "RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:package.json||{90A6B3A7-C1A3-4009-A288-E2FF89E96FA0}"
8
8
  },
9
9
  {
10
10
  "AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Users\\ArvindSuthar\\source\\repos\\front\\sync\\index.ts||{0F2454B1-A556-402D-A7D0-1FDE7F99DEE0}",
11
11
  "RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:index.ts||{0F2454B1-A556-402D-A7D0-1FDE7F99DEE0}"
12
+ },
13
+ {
14
+ "AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Users\\ArvindSuthar\\source\\repos\\front\\sync\\users.json||{90A6B3A7-C1A3-4009-A288-E2FF89E96FA0}",
15
+ "RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:users.json||{90A6B3A7-C1A3-4009-A288-E2FF89E96FA0}"
16
+ },
17
+ {
18
+ "AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Users\\ArvindSuthar\\source\\repos\\front\\sync\\hybridspa.ts||{0F2454B1-A556-402D-A7D0-1FDE7F99DEE0}",
19
+ "RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:hybridspa.ts||{0F2454B1-A556-402D-A7D0-1FDE7F99DEE0}"
12
20
  }
13
21
  ],
14
22
  "DocumentGroupContainers": [
15
23
  {
16
- "Orientation": 1,
24
+ "Orientation": 0,
17
25
  "VerticalTabListWidth": 256,
18
26
  "DocumentGroups": [
19
27
  {
20
- "DockedHeight": 221,
28
+ "DockedWidth": 200,
21
29
  "SelectedChildIndex": -1,
22
30
  "Children": [
23
31
  {
@@ -55,9 +63,48 @@
55
63
  ]
56
64
  },
57
65
  {
58
- "DockedHeight": 299,
59
- "SelectedChildIndex": 1,
66
+ "DockedWidth": 200,
67
+ "SelectedChildIndex": 0,
60
68
  "Children": [
69
+ {
70
+ "$type": "Document",
71
+ "DocumentIndex": 0,
72
+ "Title": "package.json",
73
+ "DocumentMoniker": "C:\\Users\\ArvindSuthar\\source\\repos\\front\\sync\\package.json",
74
+ "RelativeDocumentMoniker": "package.json",
75
+ "ToolTip": "C:\\Users\\ArvindSuthar\\source\\repos\\front\\sync\\package.json",
76
+ "RelativeToolTip": "package.json",
77
+ "ViewState": "AQIAAAAAAAAAAAAAAAAAAAAAAAAAAAAA",
78
+ "Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.001642|",
79
+ "WhenOpened": "2024-11-06T06:24:37.385Z",
80
+ "EditorCaption": ""
81
+ },
82
+ {
83
+ "$type": "Document",
84
+ "DocumentIndex": 2,
85
+ "Title": "users.json",
86
+ "DocumentMoniker": "C:\\Users\\ArvindSuthar\\source\\repos\\front\\sync\\users.json",
87
+ "RelativeDocumentMoniker": "users.json",
88
+ "ToolTip": "C:\\Users\\ArvindSuthar\\source\\repos\\front\\sync\\users.json",
89
+ "RelativeToolTip": "users.json",
90
+ "ViewState": "AQIAAAAAAAAAAAAAAAAAAAUAAAASAAAA",
91
+ "Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.001642|",
92
+ "WhenOpened": "2024-11-05T22:57:19.003Z",
93
+ "EditorCaption": ""
94
+ },
95
+ {
96
+ "$type": "Document",
97
+ "DocumentIndex": 3,
98
+ "Title": "hybridspa.ts",
99
+ "DocumentMoniker": "C:\\Users\\ArvindSuthar\\source\\repos\\front\\sync\\hybridspa.ts",
100
+ "RelativeDocumentMoniker": "hybridspa.ts",
101
+ "ToolTip": "C:\\Users\\ArvindSuthar\\source\\repos\\front\\sync\\hybridspa.ts",
102
+ "RelativeToolTip": "hybridspa.ts",
103
+ "ViewState": "AQIAAPgAAAAAAAAAAAAAAFECAAAXAAAA",
104
+ "Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.003213|",
105
+ "WhenOpened": "2024-11-04T14:16:26.493Z",
106
+ "EditorCaption": ""
107
+ },
61
108
  {
62
109
  "$type": "Document",
63
110
  "DocumentIndex": 1,
@@ -66,27 +113,15 @@
66
113
  "RelativeDocumentMoniker": "index.ts",
67
114
  "ToolTip": "C:\\Users\\ArvindSuthar\\source\\repos\\front\\sync\\index.ts",
68
115
  "RelativeToolTip": "index.ts",
69
- "ViewState": "AQIAAMEAAAAAAAAAAAAAAE0FAAAAAAAA",
70
- "Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.003213|",
71
- "WhenOpened": "2024-05-12T20:20:11.888Z"
72
- },
73
- {
74
- "$type": "Document",
75
- "DocumentIndex": 0,
76
- "Title": "index.d.ts",
77
- "DocumentMoniker": "C:\\Users\\ArvindSuthar\\source\\repos\\front\\sync\\index.d.ts",
78
- "RelativeDocumentMoniker": "index.d.ts",
79
- "ToolTip": "C:\\Users\\ArvindSuthar\\source\\repos\\front\\sync\\index.d.ts",
80
- "RelativeToolTip": "index.d.ts",
81
- "ViewState": "AQIAADYAAAAAAAAAAIApwLgAAAAAAAAA",
116
+ "ViewState": "AQIAAFgBAAAAAAAAAAAuwHMBAAAAAAAA",
82
117
  "Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.003213|",
83
- "WhenOpened": "2024-03-31T03:51:46.193Z",
118
+ "WhenOpened": "2024-05-12T20:20:11.888Z",
84
119
  "EditorCaption": ""
85
120
  }
86
121
  ]
87
122
  },
88
123
  {
89
- "DockedHeight": 200,
124
+ "DockedWidth": 294,
90
125
  "SelectedChildIndex": -1,
91
126
  "Children": [
92
127
  {
@@ -96,7 +131,7 @@
96
131
  ]
97
132
  },
98
133
  {
99
- "DockedHeight": 200,
134
+ "DockedWidth": 294,
100
135
  "SelectedChildIndex": -1,
101
136
  "Children": [
102
137
  {
package/index.d.ts CHANGED
@@ -79,6 +79,7 @@ declare module "@mindline/sync" {
79
79
  spacode: string;
80
80
  graphAccessToken: string;
81
81
  mindlineAccessToken: string;
82
+ azureAccessToken: string;
82
83
  loginHint: string;
83
84
  scopes: string[];
84
85
  authTS: Date;
package/index.ts CHANGED
@@ -139,7 +139,7 @@ export class User {
139
139
  this.oid = "";
140
140
  this.name = "";
141
141
  this.mail = "";
142
- this.authority = "https://login.microsoftonline.com/";
142
+ this.authority = "";
143
143
  this.tid = "";
144
144
  this.companyName = "";
145
145
  this.companyDomain = "";
@@ -437,6 +437,8 @@ export class InitInfo {
437
437
  newuser.session = user.session;
438
438
  newuser.spacode = user.spacode;
439
439
  newuser.graphAccessToken = user.graphAccessToken;
440
+ newuser.mindlineAccessToken = user.mindlineAccessToken;
441
+ newuser.azureAccessToken = user.azureAccessToken;
440
442
  newuser.loginHint = user.loginHint;
441
443
  newuser.scopes = user.scopes;
442
444
  newuser.authTS = new Date(user.authTS);
@@ -1371,7 +1373,7 @@ async function graphDefineHeaders(
1371
1373
  code: user.spacode,
1372
1374
  });
1373
1375
  user.graphAccessToken = response.accessToken; // cache access token
1374
- console.log("Front end token acquired: " + user.graphAccessToken.slice(0, 20));
1376
+ console.log("Front end token acquired by code: " + user.graphAccessToken.slice(0, 20));
1375
1377
  }
1376
1378
  catch (error: any) {
1377
1379
  console.log("Front end token failure: " + error);
@@ -1542,7 +1544,9 @@ export async function signIn(user: User, tasks: TaskArray): Promise<boolean> {
1542
1544
  let url: URL = new URL(signinURL);
1543
1545
  url.searchParams.append("redirectUri", window.location.origin);
1544
1546
  url.searchParams.append("domainHint", "organizations");
1545
- if (user.oid !== "1") { // "1" means no mail has been set by admin initially in the app, oid and mail should be same if user has set and not yet signed in
1547
+ // "1" is the OID that is set by default when reading the user objects from the JSON initialization file.
1548
+ // This means this user has not been created by the admin. If it had been, oid and mail would be the same and not == "1".
1549
+ if (user.oid !== "1") {
1546
1550
  url.searchParams.append("loginHint", user.mail);
1547
1551
  }
1548
1552
  tasks.setTaskStart("initialization", new Date());
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@mindline/sync",
3
3
  "type": "module",
4
- "version": "1.0.78",
4
+ "version": "1.0.81",
5
5
  "types": "index.d.ts",
6
6
  "exports": "./index.ts",
7
7
  "description": "sync is a node.js package encapsulating javscript classes required for configuring Mindline sync service.",
package/users.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "oid": "1",
4
4
  "name": "",
5
5
  "mail": "",
6
- "authority": "https://login.microsoftonline.com/",
6
+ "authority": "",
7
7
  "tid": "",
8
8
  "companyName": "",
9
9
  "companyDomain": "",