@quesmed/types-rn 2.5.6 → 2.5.8

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.
@@ -1,6 +1,7 @@
1
1
  import { IChapter } from './Chapter';
2
2
  import { ITopic } from './Topic';
3
3
  import { Id } from './Type';
4
+ import { EUserLearningStatus } from './User';
4
5
  import { IVideo } from './Video';
5
6
  export interface IConcept {
6
7
  id: Id;
@@ -21,4 +22,5 @@ export interface IConcept {
21
22
  yellowCards?: number | null;
22
23
  redCards?: number | null;
23
24
  dailyFeedCards?: number | null;
25
+ status?: EUserLearningStatus | null;
24
26
  }
package/models/Topic.d.ts CHANGED
@@ -53,4 +53,8 @@ export interface ITopic {
53
53
  yellowCards?: number | null;
54
54
  redCards?: number | null;
55
55
  dailyFeedCards?: number | null;
56
+ unreadConcepts?: number | null;
57
+ completedConcepts?: number | null;
58
+ revisingConcepts?: number | null;
59
+ urgentConcepts?: number | null;
56
60
  }
package/models/User.d.ts CHANGED
@@ -1,9 +1,8 @@
1
1
  import { ICard } from './Card';
2
2
  import { IConcept } from './Concept';
3
3
  import { IMarksheet, IMarksheetMark } from './Marksheet';
4
- import { IQuestionHighlights } from './Question';
5
4
  import { INotification } from './Notification';
6
- import { IQuestion } from './Question';
5
+ import { IQuestion, IQuestionHighlights } from './Question';
7
6
  import { ISubscription } from './Subscription';
8
7
  import { ITodo } from './Todo';
9
8
  import { Id } from './Type';
@@ -15,11 +14,12 @@ export declare enum EClassYearGroup {
15
14
  PRECLINICAL = 0,
16
15
  CLINICAL = 1
17
16
  }
18
- export declare enum EUserConceptStatus {
19
- UNREAD = 0,
20
- COMPLETED = 1,
21
- UN_IMPORTANT = 2,
22
- IMPORTANT = 3
17
+ export declare enum EUserLearningStatus {
18
+ ALL = 0,
19
+ UNREAD = 1,
20
+ COMPLETED = 2,
21
+ REVISING = 3,
22
+ URGENT = 4
23
23
  }
24
24
  export declare const classYearGroup: {
25
25
  [key: string]: EClassYearGroup;
@@ -179,7 +179,7 @@ export interface IUserConceptStatus {
179
179
  updatedAt: number | Date;
180
180
  conceptId: Id;
181
181
  userId: Id;
182
- status: EUserConceptStatus;
182
+ status: EUserLearningStatus;
183
183
  user: IUser;
184
184
  concept: IConcept;
185
185
  }
package/models/User.js CHANGED
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.currentClassGroup = exports.currentClassYear = exports.EPracticeIntensity = exports.classYearGroup = exports.EUserConceptStatus = exports.EClassYearGroup = exports.classYears = void 0;
3
+ exports.currentClassGroup = exports.currentClassYear = exports.EPracticeIntensity = exports.classYearGroup = exports.EUserLearningStatus = exports.EClassYearGroup = exports.classYears = void 0;
4
4
  const luxon_1 = require("luxon");
5
5
  exports.classYears = [
6
6
  'Year 1',
@@ -15,13 +15,14 @@ var EClassYearGroup;
15
15
  EClassYearGroup[EClassYearGroup["PRECLINICAL"] = 0] = "PRECLINICAL";
16
16
  EClassYearGroup[EClassYearGroup["CLINICAL"] = 1] = "CLINICAL";
17
17
  })(EClassYearGroup = exports.EClassYearGroup || (exports.EClassYearGroup = {}));
18
- var EUserConceptStatus;
19
- (function (EUserConceptStatus) {
20
- EUserConceptStatus[EUserConceptStatus["UNREAD"] = 0] = "UNREAD";
21
- EUserConceptStatus[EUserConceptStatus["COMPLETED"] = 1] = "COMPLETED";
22
- EUserConceptStatus[EUserConceptStatus["UN_IMPORTANT"] = 2] = "UN_IMPORTANT";
23
- EUserConceptStatus[EUserConceptStatus["IMPORTANT"] = 3] = "IMPORTANT";
24
- })(EUserConceptStatus = exports.EUserConceptStatus || (exports.EUserConceptStatus = {}));
18
+ var EUserLearningStatus;
19
+ (function (EUserLearningStatus) {
20
+ EUserLearningStatus[EUserLearningStatus["ALL"] = 0] = "ALL";
21
+ EUserLearningStatus[EUserLearningStatus["UNREAD"] = 1] = "UNREAD";
22
+ EUserLearningStatus[EUserLearningStatus["COMPLETED"] = 2] = "COMPLETED";
23
+ EUserLearningStatus[EUserLearningStatus["REVISING"] = 3] = "REVISING";
24
+ EUserLearningStatus[EUserLearningStatus["URGENT"] = 4] = "URGENT";
25
+ })(EUserLearningStatus = exports.EUserLearningStatus || (exports.EUserLearningStatus = {}));
25
26
  exports.classYearGroup = {
26
27
  'Year 1': EClassYearGroup.PRECLINICAL,
27
28
  'Year 2': EClassYearGroup.PRECLINICAL,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@quesmed/types-rn",
3
- "version": "2.5.6",
3
+ "version": "2.5.8",
4
4
  "description": "Typescript types for Quesmed",
5
5
  "keywords": [
6
6
  "quesmed",
@@ -74,6 +74,7 @@ exports.MARKSHEET_MARK_FIELDS = (0, client_1.gql) `
74
74
  concept {
75
75
  id
76
76
  name
77
+ status
77
78
  chapter {
78
79
  id
79
80
  explanation
@@ -126,6 +126,7 @@ exports.BUILD_QUESTION_MARKSHEET = (0, client_1.gql) `
126
126
  concept {
127
127
  id
128
128
  name
129
+ status
129
130
  topic {
130
131
  id
131
132
  name
@@ -250,6 +251,7 @@ exports.BUILD_QUESTION_MARKSHEET = (0, client_1.gql) `
250
251
  concept {
251
252
  id
252
253
  name
254
+ status
253
255
  topic {
254
256
  id
255
257
  name
@@ -377,6 +379,7 @@ exports.BUILD_QUESTION_MARKSHEET = (0, client_1.gql) `
377
379
  concept {
378
380
  id
379
381
  name
382
+ status
380
383
  topic {
381
384
  id
382
385
  name
@@ -501,6 +504,7 @@ exports.BUILD_QUESTION_MARKSHEET = (0, client_1.gql) `
501
504
  concept {
502
505
  id
503
506
  name
507
+ status
504
508
  topic {
505
509
  id
506
510
  name
@@ -721,6 +725,7 @@ exports.BUILD_MARKSHEET = (0, client_1.gql) `
721
725
  concept {
722
726
  id
723
727
  name
728
+ status
724
729
  topic {
725
730
  id
726
731
  name
@@ -845,6 +850,7 @@ exports.BUILD_MARKSHEET = (0, client_1.gql) `
845
850
  concept {
846
851
  id
847
852
  name
853
+ status
848
854
  topic {
849
855
  id
850
856
  name
@@ -972,6 +978,7 @@ exports.BUILD_MARKSHEET = (0, client_1.gql) `
972
978
  concept {
973
979
  id
974
980
  name
981
+ status
975
982
  topic {
976
983
  id
977
984
  name
@@ -1096,6 +1103,7 @@ exports.BUILD_MARKSHEET = (0, client_1.gql) `
1096
1103
  concept {
1097
1104
  id
1098
1105
  name
1106
+ status
1099
1107
  topic {
1100
1108
  id
1101
1109
  name
@@ -1321,6 +1329,7 @@ exports.RE_BUILD_MARKSHEET = (0, client_1.gql) `
1321
1329
  concept {
1322
1330
  id
1323
1331
  name
1332
+ status
1324
1333
  topic {
1325
1334
  id
1326
1335
  name
@@ -1445,6 +1454,7 @@ exports.RE_BUILD_MARKSHEET = (0, client_1.gql) `
1445
1454
  concept {
1446
1455
  id
1447
1456
  name
1457
+ status
1448
1458
  topic {
1449
1459
  id
1450
1460
  name
@@ -1572,6 +1582,7 @@ exports.RE_BUILD_MARKSHEET = (0, client_1.gql) `
1572
1582
  concept {
1573
1583
  id
1574
1584
  name
1585
+ status
1575
1586
  topic {
1576
1587
  id
1577
1588
  name
@@ -1696,6 +1707,7 @@ exports.RE_BUILD_MARKSHEET = (0, client_1.gql) `
1696
1707
  concept {
1697
1708
  id
1698
1709
  name
1710
+ status
1699
1711
  topic {
1700
1712
  id
1701
1713
  name
@@ -1,4 +1,4 @@
1
- import { EUserConceptStatus, Id, IUser, IUserConceptStatus } from '../../../models';
1
+ import { EUserLearningStatus, Id, IUser, IUserConceptStatus } 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 {
@@ -40,8 +40,8 @@ export type ITocAcceptVar = null;
40
40
  export type ITocAcceptData = RestrictedData<string, 'tocAccept'>;
41
41
  export type ICompletedCardsData = Pick<IUser, 'completedCards' | 'completedCardsCount'>;
42
42
  export type IUpsertUserConceptStatusVar = {
43
- conceptId: Id;
44
- status: EUserConceptStatus;
43
+ conceptIds: Id[];
44
+ status: EUserLearningStatus;
45
45
  };
46
- export type IUpsertUserConceptStatusData = RestrictedData<graphqlNormalize & IUserConceptStatus, 'upsertUserConceptStatus'>;
46
+ export type IUpsertUserConceptStatusData = RestrictedData<graphqlNormalize & IUserConceptStatus[], 'upsertUserConceptStatus'>;
47
47
  export declare const UPSERT_USER_CONCEPT_STATUS: import("@apollo/client").DocumentNode;
@@ -56,9 +56,9 @@ exports.TOC_ACCEPT = (0, client_1.gql) `
56
56
  }
57
57
  `;
58
58
  exports.UPSERT_USER_CONCEPT_STATUS = (0, client_1.gql) `
59
- mutation IpsertUserConceptStatus($conceptId: Int!, $status: Int!) {
59
+ mutation UpsertUserConceptStatus($conceptIds: [Int!]!, $status: Int!) {
60
60
  restricted {
61
- upsertUserConceptStatus(conceptId: $conceptId, status: $status) {
61
+ upsertUserConceptStatus(conceptIds: $conceptIds, status: $status) {
62
62
  id
63
63
  status
64
64
  conceptId
@@ -133,6 +133,7 @@ exports.MARKSHEET = (0, client_1.gql) `
133
133
  concept {
134
134
  id
135
135
  name
136
+ status
136
137
  topic {
137
138
  id
138
139
  name
@@ -257,6 +258,7 @@ exports.MARKSHEET = (0, client_1.gql) `
257
258
  concept {
258
259
  id
259
260
  name
261
+ status
260
262
  chapter {
261
263
  id
262
264
  explanation
@@ -379,6 +381,7 @@ exports.MARKSHEET = (0, client_1.gql) `
379
381
  concept {
380
382
  id
381
383
  name
384
+ status
382
385
  topic {
383
386
  id
384
387
  name
@@ -503,6 +506,7 @@ exports.MARKSHEET = (0, client_1.gql) `
503
506
  concept {
504
507
  id
505
508
  name
509
+ status
506
510
  topic {
507
511
  id
508
512
  name
@@ -716,6 +720,7 @@ exports.FLAGGED_QUESTIONS = (0, client_1.gql) `
716
720
  concept {
717
721
  id
718
722
  name
723
+ status
719
724
  topic {
720
725
  name
721
726
  typeId
@@ -842,6 +847,7 @@ exports.FLAGGED_QUESTIONS = (0, client_1.gql) `
842
847
  concept {
843
848
  id
844
849
  name
850
+ status
845
851
  topic {
846
852
  id
847
853
  name
@@ -966,6 +972,7 @@ exports.FLAGGED_QUESTIONS = (0, client_1.gql) `
966
972
  concept {
967
973
  id
968
974
  name
975
+ status
969
976
  topic {
970
977
  id
971
978
  name
@@ -1093,6 +1100,7 @@ exports.FLAGGED_QUESTIONS = (0, client_1.gql) `
1093
1100
  concept {
1094
1101
  id
1095
1102
  name
1103
+ status
1096
1104
  topic {
1097
1105
  id
1098
1106
  name
@@ -1217,6 +1225,7 @@ exports.FLAGGED_QUESTIONS = (0, client_1.gql) `
1217
1225
  concept {
1218
1226
  id
1219
1227
  name
1228
+ status
1220
1229
  topic {
1221
1230
  id
1222
1231
  name
@@ -1430,6 +1439,7 @@ exports.FLAGGED_QUESTIONS_MARKSHEET = (0, client_1.gql) `
1430
1439
  concept {
1431
1440
  id
1432
1441
  name
1442
+ status
1433
1443
  topic {
1434
1444
  id
1435
1445
  name
@@ -1554,6 +1564,7 @@ exports.FLAGGED_QUESTIONS_MARKSHEET = (0, client_1.gql) `
1554
1564
  concept {
1555
1565
  id
1556
1566
  name
1567
+ status
1557
1568
  topic {
1558
1569
  id
1559
1570
  name
@@ -1681,6 +1692,7 @@ exports.FLAGGED_QUESTIONS_MARKSHEET = (0, client_1.gql) `
1681
1692
  concept {
1682
1693
  id
1683
1694
  name
1695
+ status
1684
1696
  topic {
1685
1697
  id
1686
1698
  name
@@ -1805,6 +1817,7 @@ exports.FLAGGED_QUESTIONS_MARKSHEET = (0, client_1.gql) `
1805
1817
  concept {
1806
1818
  id
1807
1819
  name
1820
+ status
1808
1821
  topic {
1809
1822
  id
1810
1823
  name
@@ -2,7 +2,7 @@ import { 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 */
5
- typeId?: ETopicType;
5
+ typeId?: ETopicType[];
6
6
  };
7
7
  export type IQuesBookData = RestrictedData<(graphqlNormalize & ITopic)[], 'quesBook'>;
8
8
  export declare const QUES_BOOK: import("@apollo/client").DocumentNode;
@@ -4,14 +4,20 @@ exports.OSCE_BOOK = exports.QUES_BOOK = void 0;
4
4
  const client_1 = require("@apollo/client");
5
5
  const osce_1 = require("./../../fragments/osce");
6
6
  exports.QUES_BOOK = (0, client_1.gql) `
7
- query quesBook($typeId: Int) {
7
+ query quesBook($typeId: [Int]) {
8
8
  restricted {
9
9
  quesBook(typeId: $typeId) {
10
10
  id
11
11
  name
12
+ typeId
13
+ unreadConcepts
14
+ completedConcepts
15
+ revisingConcepts
16
+ urgentConcepts
12
17
  concepts {
13
18
  id
14
19
  name
20
+ status
15
21
  chapter {
16
22
  id
17
23
  typeId
@@ -66,6 +66,7 @@ exports.QUESTION = (0, client_1.gql) `
66
66
  concept {
67
67
  id
68
68
  name
69
+ status
69
70
  chapter {
70
71
  id
71
72
  explanation
@@ -187,6 +188,7 @@ exports.QUESTION = (0, client_1.gql) `
187
188
  concept {
188
189
  id
189
190
  name
191
+ status
190
192
  chapter {
191
193
  id
192
194
  explanation
@@ -311,6 +313,7 @@ exports.QUESTION = (0, client_1.gql) `
311
313
  concept {
312
314
  id
313
315
  name
316
+ status
314
317
  chapter {
315
318
  id
316
319
  explanation
@@ -432,6 +435,7 @@ exports.QUESTION = (0, client_1.gql) `
432
435
  concept {
433
436
  id
434
437
  name
438
+ status
435
439
  chapter {
436
440
  id
437
441
  explanation