@quesmed/types 2.2.77 → 2.2.80

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.
@@ -11,12 +11,12 @@ export interface IMarksheetGroup {
11
11
  users: IUser[];
12
12
  }
13
13
  /**
14
- * onMarksheetActionInfoChange
14
+ * onMarksheetChange
15
15
  */
16
- export interface IOnMarksheetActionInfoChangeVar {
16
+ export interface IOnMarksheetChangeVar {
17
17
  marksheetId: Id;
18
18
  }
19
- export interface IMarksheetActionInfo {
19
+ export interface IMarksheetInfo {
20
20
  state: EMarksheetState;
21
21
  marksheetId: Id;
22
22
  agoraId: string;
@@ -28,13 +28,13 @@ export interface IMarksheetActionInfo {
28
28
  users: IUser[];
29
29
  activeUsers: IUser[];
30
30
  }
31
- export declare type IOnMarksheetActionChangeData = RootData<IMarksheetActionInfo, 'onMarksheetActionInfoChange'>;
32
- export declare const ON_MARKSHEET_ACTION_INFO_CHANGE_KEY = "ON_MARKSHEET_ACTION_INFO_CHANGE";
33
- export declare const ON_MARKSHEET_ACTION_INFO_CHANGE: import("@apollo/client").DocumentNode;
31
+ export declare type IOnMarksheetChangeData = RootData<IMarksheetInfo, 'onMarksheetChange'>;
32
+ export declare const ON_MARKSHEET_CHANGE_KEY = "ON_MARKSHEET_CHANGE_KEY";
33
+ export declare const ON_MARKSHEET_CHANGE: import("@apollo/client").DocumentNode;
34
34
  /**
35
- * onPreStartMarksheetModification
35
+ * onPreStartMarksheetChange
36
36
  */
37
- export interface IOnPreStartMarksheetModificationVar {
37
+ export interface IOnPreStartMarksheetChangeVar {
38
38
  marksheetId: Id;
39
39
  }
40
40
  export interface IPreStartMarksheetData {
@@ -45,16 +45,16 @@ export interface IPreStartMarksheetData {
45
45
  marksheetId: Id;
46
46
  user: IUser;
47
47
  }
48
- export declare type IOnPreStartMarksheetModificationData = RootData<IPreStartMarksheetData, 'onPreStartMarksheetModification'>;
49
- export declare const ON_PRESTART_MARKSHEET_MODIFICATION_KEY = "ON_PRESTART_MARKSHEET_MODIFICATION";
50
- export declare const ON_PRESTART_MARKSHEET_MODIFICATION: import("@apollo/client").DocumentNode;
48
+ export declare type IOnPreStartMarksheetChangeData = RootData<IPreStartMarksheetData, 'onPreStartMarksheetChange'>;
49
+ export declare const ON_PRESTART_MARKSHEET_CHANGE_KEY = "ON_PRESTART_MARKSHEET_CHANGE_KEY";
50
+ export declare const ON_PRESTART_MARKSHEET_CHANGE: import("@apollo/client").DocumentNode;
51
51
  /**
52
- * OnMarksheetDataModification
52
+ * onMarksheetMarkChange
53
53
  */
54
- export interface IOnMarksheetDataModificationVar {
54
+ export interface IOnMarksheetMarkChangeVar {
55
55
  marksheetId: Id;
56
56
  }
57
- export interface IMarksheetDataModification {
57
+ export interface IMarksheetMarkData {
58
58
  action?: EMarksheetAction;
59
59
  isAnswered?: boolean;
60
60
  mark?: IMarksheetMarkJSONB;
@@ -68,6 +68,6 @@ export interface IMarksheetDataModification {
68
68
  user: IUser;
69
69
  striked?: number[];
70
70
  }
71
- export declare type IOnMarksheetDataModificationData = RootData<IMarksheetDataModification, 'onMarksheetDataModification'>;
72
- export declare const ON_MARKSHEET_DATA_MODIFICATION_KEY = "ON_MARKSHEET_DATA_MODIFICATION";
73
- export declare const ON_MARKSHEET_DATA_MODIFICATION: import("@apollo/client").DocumentNode;
71
+ export declare type IOnMarksheetMarkChangeData = RootData<IMarksheetMarkData, 'onMarksheetMarkChange'>;
72
+ export declare const ON_MARKSHEET_MARK_CHANGE_KEY = "ON_MARKSHEET_CHANGE_KEY";
73
+ export declare const ON_MARKSHEET_MARK_CHANGE: import("@apollo/client").DocumentNode;
@@ -1,11 +1,11 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.ON_MARKSHEET_DATA_MODIFICATION = exports.ON_MARKSHEET_DATA_MODIFICATION_KEY = exports.ON_PRESTART_MARKSHEET_MODIFICATION = exports.ON_PRESTART_MARKSHEET_MODIFICATION_KEY = exports.ON_MARKSHEET_ACTION_INFO_CHANGE = exports.ON_MARKSHEET_ACTION_INFO_CHANGE_KEY = void 0;
3
+ exports.ON_MARKSHEET_MARK_CHANGE = exports.ON_MARKSHEET_MARK_CHANGE_KEY = exports.ON_PRESTART_MARKSHEET_CHANGE = exports.ON_PRESTART_MARKSHEET_CHANGE_KEY = exports.ON_MARKSHEET_CHANGE = exports.ON_MARKSHEET_CHANGE_KEY = void 0;
4
4
  const client_1 = require("@apollo/client");
5
- exports.ON_MARKSHEET_ACTION_INFO_CHANGE_KEY = 'ON_MARKSHEET_ACTION_INFO_CHANGE';
6
- exports.ON_MARKSHEET_ACTION_INFO_CHANGE = (0, client_1.gql) `
7
- subscription OnMarksheetActionInfoChange($marksheetId: Int!) {
8
- onMarksheetActionInfoChange(marksheetId: $marksheetId) {
5
+ exports.ON_MARKSHEET_CHANGE_KEY = 'ON_MARKSHEET_CHANGE_KEY';
6
+ exports.ON_MARKSHEET_CHANGE = (0, client_1.gql) `
7
+ subscription OnMarksheetChange($marksheetId: Int!) {
8
+ onMarksheetChange(marksheetId: $marksheetId) {
9
9
  marksheetId
10
10
  agoraId
11
11
  userId
@@ -28,10 +28,10 @@ exports.ON_MARKSHEET_ACTION_INFO_CHANGE = (0, client_1.gql) `
28
28
  }
29
29
  }
30
30
  `;
31
- exports.ON_PRESTART_MARKSHEET_MODIFICATION_KEY = 'ON_PRESTART_MARKSHEET_MODIFICATION';
32
- exports.ON_PRESTART_MARKSHEET_MODIFICATION = (0, client_1.gql) `
33
- subscription OnPreStartMarksheetModification($marksheetId: Int!) {
34
- onPreStartMarksheetModification(marksheetId: $marksheetId) {
31
+ exports.ON_PRESTART_MARKSHEET_CHANGE_KEY = 'ON_PRESTART_MARKSHEET_CHANGE_KEY';
32
+ exports.ON_PRESTART_MARKSHEET_CHANGE = (0, client_1.gql) `
33
+ subscription OnPreStartMarksheetChange($marksheetId: Int!) {
34
+ onPreStartMarksheetChange(marksheetId: $marksheetId) {
35
35
  marksheetId
36
36
  topicConceptData
37
37
  action
@@ -57,10 +57,10 @@ exports.ON_PRESTART_MARKSHEET_MODIFICATION = (0, client_1.gql) `
57
57
  }
58
58
  }
59
59
  `;
60
- exports.ON_MARKSHEET_DATA_MODIFICATION_KEY = 'ON_MARKSHEET_DATA_MODIFICATION';
61
- exports.ON_MARKSHEET_DATA_MODIFICATION = (0, client_1.gql) `
62
- subscription OnMarksheetDataModification($marksheetId: Int!) {
63
- onMarksheetDataModification(marksheetId: $marksheetId) {
60
+ exports.ON_MARKSHEET_MARK_CHANGE_KEY = 'ON_MARKSHEET_CHANGE_KEY';
61
+ exports.ON_MARKSHEET_MARK_CHANGE = (0, client_1.gql) `
62
+ subscription OnMarksheetMarkChange($marksheetId: Int!) {
63
+ onMarksheetMarkChange(marksheetId: $marksheetId) {
64
64
  markId
65
65
  updatedAt
66
66
  marksheetId
@@ -86,9 +86,9 @@ export interface IStartOrJoinMarksheetVar {
86
86
  export declare type IStartOrJoinMarksheetData = RestrictedData<graphqlNormalize & IMarksheet, 'startOrJoinMarksheet'>;
87
87
  export declare const START_OR_JOIN_MARKSHEET: import("@apollo/client").DocumentNode;
88
88
  /**
89
- * modifyMarksheetInfo
89
+ * modifyMarksheet
90
90
  */
91
- export interface IMarksheetAction {
91
+ export interface IMarksheetDataInfo {
92
92
  userId?: Id;
93
93
  user?: IUser;
94
94
  startedAt?: Date | null;
@@ -98,6 +98,11 @@ export interface IMarksheetAction {
98
98
  users?: IUser[];
99
99
  activeUsers?: IUser[];
100
100
  }
101
+ export interface IPreStartMarksheetDataInfo {
102
+ topicConceptData?: string;
103
+ builderConfig?: IBuildConfigData;
104
+ preBuildData?: IPreBuildMarksheet;
105
+ }
101
106
  export interface IMarkDataInfo {
102
107
  markId?: Id;
103
108
  markIndex?: number;
@@ -120,21 +125,21 @@ export interface IBuildConfigData {
120
125
  isTest?: boolean;
121
126
  }
122
127
  export interface IQbankInfoInput {
123
- marksheetAction?: IMarksheetAction;
124
- topicConceptData?: string;
125
- builderConfig?: IBuildConfigData;
128
+ marksheetData?: IMarksheetDataInfo;
129
+ preStartData?: IPreStartMarksheetDataInfo;
126
130
  markData?: IMarkDataInfo;
127
131
  action?: EMarksheetAction;
128
132
  marksheetId: Id;
129
133
  }
130
- export interface IModifyMarksheetInfo {
131
- input: IQbankInfoInput;
134
+ export declare type IModifyMarksheetVarInput = Omit<IQbankInfoInput, 'markData'>;
135
+ export interface IModifyMarksheetVar {
136
+ input: Omit<IQbankInfoInput, 'markData'>;
132
137
  }
133
- export declare type IModifyMarksheetData = RestrictedData<graphqlNormalize & IMarksheet, 'modifyMarksheetInfo'>;
138
+ export declare type IModifyMarksheetData = RestrictedData<graphqlNormalize & IMarksheet, 'modifyMarksheet'>;
134
139
  export declare const optimisticModifyMarksheetBuilderConfig: (marksheetId: number, builderConfig: IBuildConfigData, client?: ApolloClient<any> | undefined) => {
135
140
  restricted: {
136
141
  __typename: string;
137
- modifyMarksheetInfo: {
142
+ modifyMarksheet: {
138
143
  builderConfig: {
139
144
  numberOfQuestions?: number | undefined;
140
145
  difficulty?: number[] | undefined;
@@ -176,7 +181,38 @@ export declare const optimisticModifyMarksheetBuilderConfig: (marksheetId: numbe
176
181
  };
177
182
  };
178
183
  };
179
- export declare const MODIFY_MARKSHEET_INFO: import("@apollo/client").DocumentNode;
184
+ export declare const MODIFY_MARKSHEET: import("@apollo/client").DocumentNode;
185
+ /**
186
+ * MODIFY_BUILDER_CONFIG
187
+ */
188
+ export declare const MODIFY_BUILDER_CONFIG: import("@apollo/client").DocumentNode;
189
+ export declare const MODIFY_BUILDER_CONFIG_FRAGMENT: import("@apollo/client").DocumentNode;
190
+ /**
191
+ * MODIFY_TOPIC_SELECTION
192
+ */
193
+ export declare const MODIFY_TOPIC_SELECTION: import("@apollo/client").DocumentNode;
194
+ export declare const MODIFY_TOPIC_SELECTION_FRAGMENT: import("@apollo/client").DocumentNode;
195
+ export declare const MODIFY_CURRENT_MARK_FRAGMENT: import("@apollo/client").DocumentNode;
196
+ /**
197
+ * MODIFY_MARKSHEET_STATE
198
+ */
199
+ export declare const MODIFY_MARKSHEET_STATE: import("@apollo/client").DocumentNode;
200
+ export declare const MODIFY_MARKSHEET_STATE_FRAGMENT: import("@apollo/client").DocumentNode;
201
+ /**
202
+ * modifyMarksheetMark
203
+ */
204
+ export declare type IModifyMarksheetMarkVarInput = Required<Pick<IQbankInfoInput, 'action' | 'markData' | 'marksheetId'>>;
205
+ export interface IModifyMarksheetMarkVar {
206
+ input: IModifyMarksheetMarkVarInput;
207
+ }
208
+ export declare type IModifyMarksheetMarkData = RestrictedData<graphqlNormalize & IMarksheetMark, 'modifyMarksheetMark'>;
209
+ export declare const MODIFY_MARKSHEET_MARK: import("@apollo/client").DocumentNode;
210
+ export declare const MODIFY_MARKSHEET_MARK_STRIKED: import("@apollo/client").DocumentNode;
211
+ export declare const MODIFY_MARKSHEET_MARK_STRIKED_FRAGMENT: import("@apollo/client").DocumentNode;
212
+ export declare const MODIFY_MARKSHEET_MARK_QUESTIONCHOICEID: import("@apollo/client").DocumentNode;
213
+ export declare const MODIFY_MARKSHEET_MARK_QUESTIONCHOICEID_FRAGMENT: import("@apollo/client").DocumentNode;
214
+ export declare const MODIFY_CURRENT_MARKSHEET_MARK: import("@apollo/client").DocumentNode;
215
+ export declare const MODIFY_CURRENT_MARKSHEET_MARK_FRAGMENT: import("@apollo/client").DocumentNode;
180
216
  /**
181
217
  * leaveMarksheet
182
218
  */