@quesmed/types-rn 2.5.9 → 2.5.11

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/models/Topic.d.ts CHANGED
@@ -57,4 +57,8 @@ export interface ITopic {
57
57
  completedConcepts?: number | null;
58
58
  revisingConcepts?: number | null;
59
59
  urgentConcepts?: number | null;
60
+ unwatchedVideos?: number | null;
61
+ completedVideos?: number | null;
62
+ revisingVideos?: number | null;
63
+ urgentVideos?: number | null;
60
64
  }
package/models/User.d.ts CHANGED
@@ -2,11 +2,13 @@ import { ICard } from './Card';
2
2
  import { IConcept } from './Concept';
3
3
  import { IMarksheet, IMarksheetMark } from './Marksheet';
4
4
  import { INotification } from './Notification';
5
+ import { IOsceStation } from './OsceStation';
5
6
  import { IQuestion, IQuestionHighlights } from './Question';
6
7
  import { ISubscription } from './Subscription';
7
8
  import { ITodo } from './Todo';
8
9
  import { Id } from './Type';
9
10
  import { IUniversity } from './University';
11
+ import { IVideo } from './Video';
10
12
  export type IAccessLevel = 'subscriber' | 'administrator' | 'tutor';
11
13
  export type IClassYear = 'Year 1' | 'Year 2' | 'Year 3' | 'Year 4' | 'Year 5' | 'Graduated' | 'PhD' | 'BSc' | 'MSc' | 'Beta Tester';
12
14
  export declare const classYears: IClassYear[];
@@ -183,3 +185,23 @@ export interface IUserConceptStatus {
183
185
  user: IUser;
184
186
  concept: IConcept;
185
187
  }
188
+ export interface IUserVideoStatus {
189
+ id: Id;
190
+ createdAt: number | Date;
191
+ updatedAt: number | Date;
192
+ userId: Id;
193
+ videoId: Id;
194
+ video: IVideo;
195
+ status: EUserLearningStatus;
196
+ user: IUser;
197
+ }
198
+ export interface IUserStationStatus {
199
+ id: Id;
200
+ createdAt: number | Date;
201
+ updatedAt: number | Date;
202
+ osceStationId: Id;
203
+ userId: Id;
204
+ status: EUserLearningStatus;
205
+ user: IUser;
206
+ station: IOsceStation;
207
+ }
package/models/Video.d.ts CHANGED
@@ -2,6 +2,7 @@ import { IConcept } from './Concept';
2
2
  import { IFile } from './File';
3
3
  import { IOsceStation } from './OsceStation';
4
4
  import { Id } from './Type';
5
+ import { EUserLearningStatus } from './User';
5
6
  export declare enum EVideoFilter {
6
7
  NEW = 0,
7
8
  POPULAR = 1,
@@ -30,6 +31,7 @@ export interface IVideo {
30
31
  send24hrPushAt: number | Date | null;
31
32
  sent24hrPushAt: number | Date | null;
32
33
  viewsToday?: number | null;
34
+ status?: EUserLearningStatus | null;
33
35
  }
34
36
  export interface IVideoOsceStation {
35
37
  id: Id;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@quesmed/types-rn",
3
- "version": "2.5.9",
3
+ "version": "2.5.11",
4
4
  "description": "Typescript types for Quesmed",
5
5
  "keywords": [
6
6
  "quesmed",
@@ -98,6 +98,7 @@ exports.MARKSHEET_MARK_FIELDS = (0, client_1.gql) `
98
98
  }
99
99
  videos {
100
100
  id
101
+ status
101
102
  title
102
103
  museId
103
104
  startTime
@@ -150,6 +150,7 @@ exports.BUILD_QUESTION_MARKSHEET = (0, client_1.gql) `
150
150
  }
151
151
  videos {
152
152
  id
153
+ status
153
154
  title
154
155
  museId
155
156
  startTime
@@ -275,6 +276,7 @@ exports.BUILD_QUESTION_MARKSHEET = (0, client_1.gql) `
275
276
  }
276
277
  videos {
277
278
  id
279
+ status
278
280
  title
279
281
  museId
280
282
  startTime
@@ -403,6 +405,7 @@ exports.BUILD_QUESTION_MARKSHEET = (0, client_1.gql) `
403
405
  }
404
406
  videos {
405
407
  id
408
+ status
406
409
  title
407
410
  museId
408
411
  startTime
@@ -528,6 +531,7 @@ exports.BUILD_QUESTION_MARKSHEET = (0, client_1.gql) `
528
531
  }
529
532
  videos {
530
533
  id
534
+ status
531
535
  title
532
536
  museId
533
537
  startTime
@@ -749,6 +753,7 @@ exports.BUILD_MARKSHEET = (0, client_1.gql) `
749
753
  }
750
754
  videos {
751
755
  id
756
+ status
752
757
  title
753
758
  museId
754
759
  startTime
@@ -874,6 +879,7 @@ exports.BUILD_MARKSHEET = (0, client_1.gql) `
874
879
  }
875
880
  videos {
876
881
  id
882
+ status
877
883
  title
878
884
  museId
879
885
  startTime
@@ -1002,6 +1008,7 @@ exports.BUILD_MARKSHEET = (0, client_1.gql) `
1002
1008
  }
1003
1009
  videos {
1004
1010
  id
1011
+ status
1005
1012
  title
1006
1013
  museId
1007
1014
  startTime
@@ -1127,6 +1134,7 @@ exports.BUILD_MARKSHEET = (0, client_1.gql) `
1127
1134
  }
1128
1135
  videos {
1129
1136
  id
1137
+ status
1130
1138
  title
1131
1139
  museId
1132
1140
  startTime
@@ -1353,6 +1361,7 @@ exports.RE_BUILD_MARKSHEET = (0, client_1.gql) `
1353
1361
  }
1354
1362
  videos {
1355
1363
  id
1364
+ status
1356
1365
  title
1357
1366
  museId
1358
1367
  startTime
@@ -1478,6 +1487,7 @@ exports.RE_BUILD_MARKSHEET = (0, client_1.gql) `
1478
1487
  }
1479
1488
  videos {
1480
1489
  id
1490
+ status
1481
1491
  title
1482
1492
  museId
1483
1493
  startTime
@@ -1606,6 +1616,7 @@ exports.RE_BUILD_MARKSHEET = (0, client_1.gql) `
1606
1616
  }
1607
1617
  videos {
1608
1618
  id
1619
+ status
1609
1620
  title
1610
1621
  museId
1611
1622
  startTime
@@ -1731,6 +1742,7 @@ exports.RE_BUILD_MARKSHEET = (0, client_1.gql) `
1731
1742
  }
1732
1743
  videos {
1733
1744
  id
1745
+ status
1734
1746
  title
1735
1747
  museId
1736
1748
  startTime
@@ -1,4 +1,4 @@
1
- import { EUserLearningStatus, Id, IUser, IUserConceptStatus } from '../../../models';
1
+ import { EUserLearningStatus, Id, IUser, IUserConceptStatus, IUserStationStatus, IUserVideoStatus } from '../../../models';
2
2
  import { graphqlNormalize, RestrictedData } from '../../types';
3
3
  export declare const RESET_PROGRESS: import("@apollo/client").DocumentNode;
4
4
  export interface IResetProgressVar {
@@ -45,3 +45,15 @@ export type IUpsertUserConceptStatusVar = {
45
45
  };
46
46
  export type IUpsertUserConceptStatusData = RestrictedData<graphqlNormalize & IUserConceptStatus[], 'upsertUserConceptStatus'>;
47
47
  export declare const UPSERT_USER_CONCEPT_STATUS: import("@apollo/client").DocumentNode;
48
+ export type IUpsertUserStationStatusVar = {
49
+ osceStationIds: Id[];
50
+ status: EUserLearningStatus;
51
+ };
52
+ export type IUpsertUserStationStatusData = RestrictedData<graphqlNormalize & IUserStationStatus[], 'upsertUserStationStatus'>;
53
+ export declare const UPSERT_USER_STATION_STATUS: import("@apollo/client").DocumentNode;
54
+ export type IUpsertUserVideoStatusVar = {
55
+ videoIds: Id[];
56
+ status: EUserLearningStatus;
57
+ };
58
+ export type IUpsertUserVideoStatusData = RestrictedData<graphqlNormalize & IUserVideoStatus[], 'upsertUserVideoStatus'>;
59
+ export declare const UPSERT_USER_VIDEO_STATUS: import("@apollo/client").DocumentNode;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.UPSERT_USER_CONCEPT_STATUS = exports.TOC_ACCEPT = exports.RENEW_TOKEN = exports.UPDATE_USER = exports.DELETE_USER = exports.RESET_PROGRESS = void 0;
3
+ exports.UPSERT_USER_VIDEO_STATUS = exports.UPSERT_USER_STATION_STATUS = exports.UPSERT_USER_CONCEPT_STATUS = exports.TOC_ACCEPT = exports.RENEW_TOKEN = exports.UPDATE_USER = exports.DELETE_USER = exports.RESET_PROGRESS = void 0;
4
4
  const client_1 = require("@apollo/client");
5
5
  exports.RESET_PROGRESS = (0, client_1.gql) `
6
6
  mutation ResetProgress($questions: Boolean, $cards: Boolean) {
@@ -68,3 +68,29 @@ exports.UPSERT_USER_CONCEPT_STATUS = (0, client_1.gql) `
68
68
  }
69
69
  }
70
70
  `;
71
+ exports.UPSERT_USER_STATION_STATUS = (0, client_1.gql) `
72
+ mutation UpsertUserStationStatus($osceStationIds: [Int!]!, $status: Int!) {
73
+ restricted {
74
+ upsertUserStationStatus(osceStationIds: $osceStationIds, status: $status) {
75
+ id
76
+ status
77
+ osceStationId
78
+ userId
79
+ createdAt
80
+ }
81
+ }
82
+ }
83
+ `;
84
+ exports.UPSERT_USER_VIDEO_STATUS = (0, client_1.gql) `
85
+ mutation UpsertUserVideoStatus($videoIds: [Int!]!, $status: Int!) {
86
+ restricted {
87
+ upsertUserVideoStatus(videoIds: $videoIds, status: $status) {
88
+ id
89
+ status
90
+ videoId
91
+ userId
92
+ createdAt
93
+ }
94
+ }
95
+ }
96
+ `;
@@ -157,6 +157,7 @@ exports.MARKSHEET = (0, client_1.gql) `
157
157
  }
158
158
  videos {
159
159
  id
160
+ status
160
161
  title
161
162
  museId
162
163
  startTime
@@ -277,6 +278,7 @@ exports.MARKSHEET = (0, client_1.gql) `
277
278
  }
278
279
  videos {
279
280
  id
281
+ status
280
282
  title
281
283
  museId
282
284
  startTime
@@ -405,6 +407,7 @@ exports.MARKSHEET = (0, client_1.gql) `
405
407
  }
406
408
  videos {
407
409
  id
410
+ status
408
411
  title
409
412
  museId
410
413
  startTime
@@ -530,6 +533,7 @@ exports.MARKSHEET = (0, client_1.gql) `
530
533
  }
531
534
  videos {
532
535
  id
536
+ status
533
537
  title
534
538
  museId
535
539
  startTime
@@ -743,6 +747,7 @@ exports.FLAGGED_QUESTIONS = (0, client_1.gql) `
743
747
  }
744
748
  videos {
745
749
  id
750
+ status
746
751
  title
747
752
  museId
748
753
  startTime
@@ -871,6 +876,7 @@ exports.FLAGGED_QUESTIONS = (0, client_1.gql) `
871
876
  }
872
877
  videos {
873
878
  id
879
+ status
874
880
  title
875
881
  museId
876
882
  startTime
@@ -996,6 +1002,7 @@ exports.FLAGGED_QUESTIONS = (0, client_1.gql) `
996
1002
  }
997
1003
  videos {
998
1004
  id
1005
+ status
999
1006
  title
1000
1007
  museId
1001
1008
  startTime
@@ -1124,6 +1131,7 @@ exports.FLAGGED_QUESTIONS = (0, client_1.gql) `
1124
1131
  }
1125
1132
  videos {
1126
1133
  id
1134
+ status
1127
1135
  title
1128
1136
  museId
1129
1137
  startTime
@@ -1249,6 +1257,7 @@ exports.FLAGGED_QUESTIONS = (0, client_1.gql) `
1249
1257
  }
1250
1258
  videos {
1251
1259
  id
1260
+ status
1252
1261
  title
1253
1262
  museId
1254
1263
  startTime
@@ -1463,6 +1472,7 @@ exports.FLAGGED_QUESTIONS_MARKSHEET = (0, client_1.gql) `
1463
1472
  }
1464
1473
  videos {
1465
1474
  id
1475
+ status
1466
1476
  title
1467
1477
  museId
1468
1478
  startTime
@@ -1588,6 +1598,7 @@ exports.FLAGGED_QUESTIONS_MARKSHEET = (0, client_1.gql) `
1588
1598
  }
1589
1599
  videos {
1590
1600
  id
1601
+ status
1591
1602
  title
1592
1603
  museId
1593
1604
  startTime
@@ -1716,6 +1727,7 @@ exports.FLAGGED_QUESTIONS_MARKSHEET = (0, client_1.gql) `
1716
1727
  }
1717
1728
  videos {
1718
1729
  id
1730
+ status
1719
1731
  title
1720
1732
  museId
1721
1733
  startTime
@@ -1841,6 +1853,7 @@ exports.FLAGGED_QUESTIONS_MARKSHEET = (0, client_1.gql) `
1841
1853
  }
1842
1854
  videos {
1843
1855
  id
1856
+ status
1844
1857
  title
1845
1858
  museId
1846
1859
  startTime
@@ -1,4 +1,4 @@
1
- import { ETopicType, IOsceStation, ITopic } from '../../../models';
1
+ import { EOsceType, ETopicType, IOsceStation, ITopic } from '../../../models';
2
2
  import { RestrictedData, graphqlNormalize } from '../../types';
3
3
  export type IQuesBookVar = {
4
4
  /**TODO: make it mandatory once frontend changes are completed */
@@ -6,6 +6,9 @@ export type IQuesBookVar = {
6
6
  };
7
7
  export type IQuesBookData = RestrictedData<(graphqlNormalize & ITopic)[], 'quesBook'>;
8
8
  export declare const QUES_BOOK: import("@apollo/client").DocumentNode;
9
- export type IOsceBookVar = null;
9
+ export type IOsceBookVar = {
10
+ /**TODO: make it mandatory once frontend changes are completed */
11
+ typeId?: EOsceType[];
12
+ };
10
13
  export type IOsceBookData = RestrictedData<(graphqlNormalize & IOsceStation)[], 'osceBook'>;
11
14
  export declare const OSCE_BOOK: import("@apollo/client").DocumentNode;
@@ -14,6 +14,10 @@ exports.QUES_BOOK = (0, client_1.gql) `
14
14
  completedConcepts
15
15
  revisingConcepts
16
16
  urgentConcepts
17
+ unwatchedVideos
18
+ completedVideos
19
+ revisingVideos
20
+ urgentVideos
17
21
  concepts {
18
22
  id
19
23
  name
@@ -37,6 +41,7 @@ exports.QUES_BOOK = (0, client_1.gql) `
37
41
  topicId
38
42
  videos {
39
43
  id
44
+ status
40
45
  title
41
46
  museId
42
47
  thumbnail
@@ -55,9 +60,9 @@ exports.QUES_BOOK = (0, client_1.gql) `
55
60
  `;
56
61
  exports.OSCE_BOOK = (0, client_1.gql) `
57
62
  ${osce_1.OSCE_STATION_FIELDS}
58
- query OsceBook {
63
+ query OsceBook($typeId: [Int]) {
59
64
  restricted {
60
- osceBook {
65
+ osceBook(typeId: $typeId) {
61
66
  ...OsceStationFields
62
67
  lastOsceMarksheetId
63
68
  score
@@ -90,6 +90,7 @@ exports.QUESTION = (0, client_1.gql) `
90
90
  }
91
91
  videos {
92
92
  id
93
+ status
93
94
  title
94
95
  museId
95
96
  startTime
@@ -212,6 +213,7 @@ exports.QUESTION = (0, client_1.gql) `
212
213
  }
213
214
  videos {
214
215
  id
216
+ status
215
217
  title
216
218
  museId
217
219
  startTime
@@ -337,6 +339,7 @@ exports.QUESTION = (0, client_1.gql) `
337
339
  }
338
340
  videos {
339
341
  id
342
+ status
340
343
  title
341
344
  museId
342
345
  startTime
@@ -459,6 +462,7 @@ exports.QUESTION = (0, client_1.gql) `
459
462
  }
460
463
  videos {
461
464
  id
465
+ status
462
466
  title
463
467
  museId
464
468
  startTime