@quesmed/types 2.2.103 → 2.3.0

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.
@@ -16,6 +16,7 @@ export declare const getQuestionTypeName: (typeId: EQuestionType) => string;
16
16
  export declare const QUESTION_LIKE: DocumentNode;
17
17
  export declare const optimisticQuestionLike: (input: IQuestionLikeVar, question: IQuestion) => IQuestionLikeData;
18
18
  export interface IQuestionLikeVar {
19
+ marksheetId: Id;
19
20
  questionId: Id;
20
21
  like: EQuestionLike;
21
22
  }
@@ -27,6 +28,7 @@ export declare const optimisticQuestionComment: (id: number, user: {
27
28
  displayName: string;
28
29
  }, input: IQuestionCommentsVar) => IQuestionCommentsData;
29
30
  export interface IQuestionCommentsVar {
31
+ marksheetId: Id;
30
32
  questionId: Id;
31
33
  parentId?: Id;
32
34
  comment: string;
@@ -35,6 +37,7 @@ export declare type IQuestionCommentsData = RestrictedData<graphqlNormalize & IQ
35
37
  export declare const QUESTION_COMMENT_LIKE: DocumentNode;
36
38
  export declare const optimisticCommentLike: (comments: IQuestionComment[], input: IQuestionCommentsLikeVar, parentId: number | null) => IQuestionCommentsLikeData;
37
39
  export interface IQuestionCommentsLikeVar {
40
+ marksheetId: Id;
38
41
  commentId: Id;
39
42
  like: EQuestionLike;
40
43
  }
@@ -43,6 +46,7 @@ export declare const QUESTION_COMMENT_REMOVE: DocumentNode;
43
46
  export declare const updateQuestionCommentsRemove: (typeId: EQuestionType) => (cache: ApolloCache<any>, result: ApolloUpdateResultRestricted<IQuestionCommentRemoveData>, options: ApolloUpdateOptions) => void;
44
47
  export declare const optimisticQuestionCommentRemove: (comments: IQuestionComment[], input: IQuestionCommentRemoveVar, parentId?: number | undefined) => IQuestionCommentRemoveData;
45
48
  export interface IQuestionCommentRemoveVar {
49
+ marksheetId: Id;
46
50
  commentId: Id;
47
51
  }
48
52
  export declare type IQuestionCommentRemoveData = RestrictedData<graphqlNormalize & IQuestionComment, 'questionCommentRemove'>;
@@ -227,9 +227,13 @@ const removeCommnetFromDiscussion = (comments, commentId, parentId) => {
227
227
  return comments.filter(({ id }) => Number(id) !== Number(commentId));
228
228
  };
229
229
  exports.QUESTION_LIKE = (0, client_1.gql) `
230
- mutation QuestionLike($questionId: Int!, $like: Int!) {
230
+ mutation QuestionLike($marksheetId: Int!, $questionId: Int!, $like: Int!) {
231
231
  restricted {
232
- questionLike(questionId: $questionId, like: $like) {
232
+ questionLike(
233
+ marksheetId: $marksheetId
234
+ questionId: $questionId
235
+ like: $like
236
+ ) {
233
237
  id
234
238
  likes
235
239
  typeId
@@ -253,12 +257,14 @@ const optimisticQuestionLike = (input, question) => {
253
257
  exports.optimisticQuestionLike = optimisticQuestionLike;
254
258
  exports.QUESTION_COMMENTS = (0, client_1.gql) `
255
259
  mutation QuestionComments(
260
+ $marksheetId: Int!
256
261
  $questionId: Int!
257
262
  $parentId: Int
258
263
  $comment: String!
259
264
  ) {
260
265
  restricted {
261
266
  questionComments(
267
+ marksheetId: $marksheetId
262
268
  questionId: $questionId
263
269
  parentId: $parentId
264
270
  comment: $comment
@@ -354,9 +360,17 @@ const optimisticQuestionComment = (id, user, input) => {
354
360
  };
355
361
  exports.optimisticQuestionComment = optimisticQuestionComment;
356
362
  exports.QUESTION_COMMENT_LIKE = (0, client_1.gql) `
357
- mutation QuestionCommentLike($commentId: Int!, $like: Int!) {
363
+ mutation QuestionCommentLike(
364
+ $marksheetId: Int!
365
+ $commentId: Int!
366
+ $like: Int!
367
+ ) {
358
368
  restricted {
359
- questionCommentLike(commentId: $commentId, like: $like) {
369
+ questionCommentLike(
370
+ marksheetId: $marksheetId
371
+ commentId: $commentId
372
+ like: $like
373
+ ) {
360
374
  id
361
375
  createdAt
362
376
  comment
@@ -408,9 +422,9 @@ const optimisticCommentLike = (comments, input, parentId) => {
408
422
  };
409
423
  exports.optimisticCommentLike = optimisticCommentLike;
410
424
  exports.QUESTION_COMMENT_REMOVE = (0, client_1.gql) `
411
- mutation QuestionCommentRemove($commentId: Int!) {
425
+ mutation QuestionCommentRemove($marksheetId: Int!, $commentId: Int!) {
412
426
  restricted {
413
- questionCommentRemove(commentId: $commentId) {
427
+ questionCommentRemove(marksheetId: $marksheetId, commentId: $commentId) {
414
428
  id
415
429
  createdAt
416
430
  comment
@@ -16,6 +16,7 @@ export declare const getQuestionTypeName: (typeId: EQuestionType) => string;
16
16
  export declare const QUESTION_LIKE: DocumentNode;
17
17
  export declare const optimisticQuestionLike: (input: IQuestionLikeVar, question: IQuestion) => IQuestionLikeData;
18
18
  export interface IQuestionLikeVar {
19
+ marksheetId: Id;
19
20
  questionId: Id;
20
21
  like: EQuestionLike;
21
22
  }
@@ -27,6 +28,7 @@ export declare const optimisticQuestionComment: (id: number, user: {
27
28
  displayName: string;
28
29
  }, input: IQuestionCommentsVar) => IQuestionCommentsData;
29
30
  export interface IQuestionCommentsVar {
31
+ marksheetId: Id;
30
32
  questionId: Id;
31
33
  parentId?: Id;
32
34
  comment: string;
@@ -35,6 +37,7 @@ export declare type IQuestionCommentsData = RestrictedData<graphqlNormalize & IQ
35
37
  export declare const QUESTION_COMMENT_LIKE: DocumentNode;
36
38
  export declare const optimisticCommentLike: (comments: IQuestionComment[], input: IQuestionCommentsLikeVar, parentId: number | null) => IQuestionCommentsLikeData;
37
39
  export interface IQuestionCommentsLikeVar {
40
+ marksheetId: Id;
38
41
  commentId: Id;
39
42
  like: EQuestionLike;
40
43
  }
@@ -43,6 +46,7 @@ export declare const QUESTION_COMMENT_REMOVE: DocumentNode;
43
46
  export declare const updateQuestionCommentsRemove: (typeId: EQuestionType) => (cache: ApolloCache<any>, result: ApolloUpdateResultRestricted<IQuestionCommentRemoveData>, options: ApolloUpdateOptions) => void;
44
47
  export declare const optimisticQuestionCommentRemove: (comments: IQuestionComment[], input: IQuestionCommentRemoveVar, parentId?: number | undefined) => IQuestionCommentRemoveData;
45
48
  export interface IQuestionCommentRemoveVar {
49
+ marksheetId: Id;
46
50
  commentId: Id;
47
51
  }
48
52
  export declare type IQuestionCommentRemoveData = RestrictedData<graphqlNormalize & IQuestionComment, 'questionCommentRemove'>;
@@ -222,9 +222,13 @@ const removeCommnetFromDiscussion = (comments, commentId, parentId) => {
222
222
  return comments.filter(({ id }) => Number(id) !== Number(commentId));
223
223
  };
224
224
  export const QUESTION_LIKE = gql `
225
- mutation QuestionLike($questionId: Int!, $like: Int!) {
225
+ mutation QuestionLike($marksheetId: Int!, $questionId: Int!, $like: Int!) {
226
226
  restricted {
227
- questionLike(questionId: $questionId, like: $like) {
227
+ questionLike(
228
+ marksheetId: $marksheetId
229
+ questionId: $questionId
230
+ like: $like
231
+ ) {
228
232
  id
229
233
  likes
230
234
  typeId
@@ -247,12 +251,14 @@ export const optimisticQuestionLike = (input, question) => {
247
251
  };
248
252
  export const QUESTION_COMMENTS = gql `
249
253
  mutation QuestionComments(
254
+ $marksheetId: Int!
250
255
  $questionId: Int!
251
256
  $parentId: Int
252
257
  $comment: String!
253
258
  ) {
254
259
  restricted {
255
260
  questionComments(
261
+ marksheetId: $marksheetId
256
262
  questionId: $questionId
257
263
  parentId: $parentId
258
264
  comment: $comment
@@ -346,9 +352,17 @@ export const optimisticQuestionComment = (id, user, input) => {
346
352
  };
347
353
  };
348
354
  export const QUESTION_COMMENT_LIKE = gql `
349
- mutation QuestionCommentLike($commentId: Int!, $like: Int!) {
355
+ mutation QuestionCommentLike(
356
+ $marksheetId: Int!
357
+ $commentId: Int!
358
+ $like: Int!
359
+ ) {
350
360
  restricted {
351
- questionCommentLike(commentId: $commentId, like: $like) {
361
+ questionCommentLike(
362
+ marksheetId: $marksheetId
363
+ commentId: $commentId
364
+ like: $like
365
+ ) {
352
366
  id
353
367
  createdAt
354
368
  comment
@@ -399,9 +413,9 @@ export const optimisticCommentLike = (comments, input, parentId) => {
399
413
  };
400
414
  };
401
415
  export const QUESTION_COMMENT_REMOVE = gql `
402
- mutation QuestionCommentRemove($commentId: Int!) {
416
+ mutation QuestionCommentRemove($marksheetId: Int!, $commentId: Int!) {
403
417
  restricted {
404
- questionCommentRemove(commentId: $commentId) {
418
+ questionCommentRemove(marksheetId: $marksheetId, commentId: $commentId) {
405
419
  id
406
420
  createdAt
407
421
  comment
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@quesmed/types",
3
- "version": "2.2.103",
3
+ "version": "2.3.0",
4
4
  "description": "Typescript types for Quesmed",
5
5
  "keywords": [
6
6
  "quesmed",