commons-assessment 12.1.0 → 12.1.2-dev.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.
- package/README.md +11 -0
- package/bundles/commons-assessment.umd.js +2304 -247
- package/bundles/commons-assessment.umd.js.map +1 -1
- package/esm2015/lib/modules/assessment-maker/assessment-maker.component.js +293 -32
- package/esm2015/lib/modules/assessment-maker/assessment-maker.module.js +10 -5
- package/esm2015/lib/modules/assessment-maker/components/add-edit-section-introduction/add-edit-section-introduction.component.js +1 -1
- package/esm2015/lib/modules/assessment-maker/components/assessment-builder/assessment-builder.component.js +77 -22
- package/esm2015/lib/modules/assessment-maker/components/question-bank-picker/question-bank-picker.component.js +276 -0
- package/esm2015/lib/modules/assessment-maker/components/question-details/question-details.component.js +22 -2
- package/esm2015/lib/modules/assessment-maker/services/assessment-builder.service.js +22 -7
- package/esm2015/lib/modules/assessment-maker/services/assessment-maker.service.js +32 -5
- package/esm2015/lib/modules/assessment-taker/assessment-taker.component.js +365 -42
- package/esm2015/lib/modules/assessment-taker/assessment-taker.module.js +9 -3
- package/esm2015/lib/modules/assessment-taker/components/proctoring-consent/proctoring-consent.component.js +137 -0
- package/esm2015/lib/modules/assessment-taker/components/proctoring-result/proctoring-result.component.js +177 -0
- package/esm2015/lib/modules/assessment-taker/components/question-type-date-picker/question-type-date-picker.component.js +2 -3
- package/esm2015/lib/modules/assessment-taker/components/question-type-editor/question-type-editor.component.js +1 -1
- package/esm2015/lib/modules/assessment-taker/components/question-type-file-upload/question-type-file-upload.component.js +5 -2
- package/esm2015/lib/modules/assessment-taker/components/question-type-long/question-type-long.component.js +1 -1
- package/esm2015/lib/modules/assessment-taker/components/question-type-multiselect/question-type-multiselect.component.js +7 -3
- package/esm2015/lib/modules/assessment-taker/components/question-type-objective/question-type-objective.component.js +7 -3
- package/esm2015/lib/modules/assessment-taker/components/question-type-preference/question-type-preference.component.js +9 -4
- package/esm2015/lib/modules/assessment-taker/components/question-type-short/question-type-short.component.js +78 -8
- package/esm2015/lib/modules/assessment-taker/components/section-instructions/section-instructions.component.js +1 -1
- package/esm2015/lib/modules/assessment-taker/services/assessment-taker.service.js +18 -3
- package/esm2015/lib/modules/assessment-taker/services/proctoring.service.js +125 -0
- package/esm2015/lib/modules/assessment-taker/services/response-builder.service.js +15 -1
- package/esm2015/lib/modules/question-bank/question-bank.component.js +313 -0
- package/esm2015/lib/modules/question-bank/question-bank.module.js +45 -0
- package/esm2015/lib/shared/components/confirmation-dialog/confirmation-dialog.component.js +56 -0
- package/esm2015/lib/shared/components/skill-allocation/skill-allocation.component.js +5 -2
- package/esm2015/lib/shared/controllers.js +18 -4
- package/esm2015/lib/shared/interfaces/assessment.interface.js +1 -1
- package/esm2015/lib/shared/interfaces/proctoring.interface.js +2 -0
- package/esm2015/lib/shared/material-modules.js +1 -16
- package/esm2015/lib/shared/shared.module.js +8 -3
- package/esm2015/lib/shared/utils.js +19 -1
- package/esm2015/public-api.js +4 -1
- package/fesm2015/commons-assessment.js +2071 -152
- package/fesm2015/commons-assessment.js.map +1 -1
- package/lib/modules/assessment-maker/assessment-maker.component.d.ts +40 -2
- package/lib/modules/assessment-maker/assessment-maker.module.d.ts +6 -5
- package/lib/modules/assessment-maker/components/assessment-builder/assessment-builder.component.d.ts +7 -0
- package/lib/modules/assessment-maker/components/question-bank-picker/question-bank-picker.component.d.ts +81 -0
- package/lib/modules/assessment-maker/components/question-details/question-details.component.d.ts +6 -1
- package/lib/modules/assessment-maker/services/assessment-builder.service.d.ts +10 -3
- package/lib/modules/assessment-maker/services/assessment-maker.service.d.ts +15 -11
- package/lib/modules/assessment-taker/assessment-taker.component.d.ts +81 -2
- package/lib/modules/assessment-taker/assessment-taker.module.d.ts +7 -5
- package/lib/modules/assessment-taker/components/proctoring-consent/proctoring-consent.component.d.ts +39 -0
- package/lib/modules/assessment-taker/components/proctoring-result/proctoring-result.component.d.ts +82 -0
- package/lib/modules/assessment-taker/components/question-type-file-upload/question-type-file-upload.component.d.ts +1 -0
- package/lib/modules/assessment-taker/components/question-type-multiselect/question-type-multiselect.component.d.ts +1 -0
- package/lib/modules/assessment-taker/components/question-type-objective/question-type-objective.component.d.ts +1 -0
- package/lib/modules/assessment-taker/components/question-type-preference/question-type-preference.component.d.ts +1 -0
- package/lib/modules/assessment-taker/components/question-type-short/question-type-short.component.d.ts +14 -2
- package/lib/modules/assessment-taker/services/assessment-taker.service.d.ts +5 -0
- package/lib/modules/assessment-taker/services/proctoring.service.d.ts +40 -0
- package/lib/modules/assessment-taker/services/response-builder.service.d.ts +9 -0
- package/lib/modules/question-bank/question-bank.component.d.ts +65 -0
- package/lib/modules/question-bank/question-bank.module.d.ts +12 -0
- package/lib/shared/components/confirmation-dialog/confirmation-dialog.component.d.ts +36 -0
- package/lib/shared/components/skill-allocation/skill-allocation.component.d.ts +1 -0
- package/lib/shared/controllers.d.ts +14 -1
- package/lib/shared/interfaces/assessment.interface.d.ts +8 -0
- package/lib/shared/interfaces/proctoring.interface.d.ts +101 -0
- package/lib/shared/material-modules.d.ts +5 -8
- package/lib/shared/shared.module.d.ts +5 -4
- package/lib/shared/utils.d.ts +4 -0
- package/package.json +1 -1
- package/public-api.d.ts +3 -0
- package/src/lib/assets/images/arrow-down-blue.svg +3 -0
- package/src/lib/assets/images/arrow-up-blue.svg +3 -0
- package/src/lib/assets/images/file-import.svg +11 -0
- package/src/lib/assets/images/plus-white.svg +1 -0
- package/src/lib/assets/images/proctoring.svg +3 -0
- package/src/lib/assets/images/user.svg +3 -0
- package/src/lib/assets/json/imageConfig.json +7 -1
- package/src/lib/assets/json/labelConfig.json +107 -2
- package/src/lib/assets/theme/_theme.global.scss +6 -0
- package/src/lib/assets/theme/_theme.scss +17 -346
- package/src/lib/assets/theme/styles.scss +13 -0
|
@@ -27,6 +27,7 @@ export declare class QuestionTypeObjectiveComponent implements ControlValueAcces
|
|
|
27
27
|
isEvaluationEnabled(): boolean;
|
|
28
28
|
getSelectionStatus(option: any): string | null;
|
|
29
29
|
imageErrorHandler(event: any, filePath: string): void;
|
|
30
|
+
trackByOptionId(index: number, option: any): string;
|
|
30
31
|
static ɵfac: i0.ɵɵFactoryDeclaration<QuestionTypeObjectiveComponent, [{ optional: true; self: true; }]>;
|
|
31
32
|
static ɵcmp: i0.ɵɵComponentDeclaration<QuestionTypeObjectiveComponent, "lib-question-type-objective", never, { "required": "required"; "question": "question"; "showCorrectAnswers": "showCorrectAnswers"; "imageConfig": "imageConfig"; "answerObj": "answerObj"; }, { "viewChild": "viewChild"; }, never, never>;
|
|
32
33
|
}
|
|
@@ -20,6 +20,7 @@ export declare class QuestionTypePreferenceComponent implements ControlValueAcce
|
|
|
20
20
|
onTouched(): void;
|
|
21
21
|
checkFormControlValid(): "" | "assessment-error-text assessment-text-danger";
|
|
22
22
|
optionDetection(obj: any, detectFromEdit: boolean): void;
|
|
23
|
+
trackByOptionId(index: number, option: any): string;
|
|
23
24
|
static ɵfac: i0.ɵɵFactoryDeclaration<QuestionTypePreferenceComponent, [{ optional: true; self: true; }]>;
|
|
24
25
|
static ɵcmp: i0.ɵɵComponentDeclaration<QuestionTypePreferenceComponent, "lib-question-type-preference", never, { "required": "required"; "question": "question"; }, { "viewChild": "viewChild"; }, never, never>;
|
|
25
26
|
}
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
import { ControlValueAccessor, FormControl, NgControl } from '@angular/forms';
|
|
2
2
|
import { AssessmentQuestion } from '../../../../shared/interfaces/question.interface';
|
|
3
|
+
import { AssessmentTakerService } from '../../services/assessment-taker.service';
|
|
3
4
|
import * as i0 from "@angular/core";
|
|
4
5
|
export declare class QuestionTypeShortComponent implements ControlValueAccessor {
|
|
5
6
|
ngControl: NgControl;
|
|
7
|
+
private assessmentTakerService;
|
|
6
8
|
required: any;
|
|
7
9
|
question: AssessmentQuestion;
|
|
8
10
|
previewMode: boolean;
|
|
@@ -11,7 +13,17 @@ export declare class QuestionTypeShortComponent implements ControlValueAccessor
|
|
|
11
13
|
};
|
|
12
14
|
formControl: FormControl;
|
|
13
15
|
onTouched: () => void;
|
|
14
|
-
constructor(ngControl: NgControl);
|
|
16
|
+
constructor(ngControl: NgControl, assessmentTakerService: AssessmentTakerService);
|
|
17
|
+
onBlur(): void;
|
|
18
|
+
private isGoogleDriveLink;
|
|
19
|
+
/**
|
|
20
|
+
* For URL-type questions, if the entered value is a Google Drive link, verify it is public.
|
|
21
|
+
* A private link sets a `privateGdriveLink` error on the (outer) control so the taker shows
|
|
22
|
+
* an invalid-input message and blocks submission. Fails open on API/network errors.
|
|
23
|
+
*/
|
|
24
|
+
validateGoogleDriveLink(): void;
|
|
25
|
+
private finishValidation;
|
|
26
|
+
private clearPrivateLinkError;
|
|
15
27
|
checkFormControlValid(): "" | "assessment-input-border-invalid";
|
|
16
28
|
writeValue(value: any): void;
|
|
17
29
|
registerOnChange(fn: Function): void;
|
|
@@ -21,6 +33,6 @@ export declare class QuestionTypeShortComponent implements ControlValueAccessor
|
|
|
21
33
|
get inputType(): string;
|
|
22
34
|
restrictNumberOnly(event: KeyboardEvent): void;
|
|
23
35
|
preventScroll(event: WheelEvent): void;
|
|
24
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<QuestionTypeShortComponent, [{ optional: true; self: true; }]>;
|
|
36
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<QuestionTypeShortComponent, [{ optional: true; self: true; }, null]>;
|
|
25
37
|
static ɵcmp: i0.ɵɵComponentDeclaration<QuestionTypeShortComponent, "lib-question-type-short", never, { "required": "required"; "question": "question"; "previewMode": "previewMode"; "labelConfig": "labelConfig"; }, {}, never, never>;
|
|
26
38
|
}
|
|
@@ -17,6 +17,11 @@ export declare class AssessmentTakerService {
|
|
|
17
17
|
patchAssessment(payload: any): import("rxjs").Observable<Object>;
|
|
18
18
|
getAnswersByAiaId(aiaId: any): import("rxjs").Observable<Object>;
|
|
19
19
|
updateMarks(payload: any): import("rxjs").Observable<Object>;
|
|
20
|
+
refreshProctoringToken(assesseeId: number): import("rxjs").Observable<Object>;
|
|
21
|
+
endProctoringSession(assesseeId: number): import("rxjs").Observable<Object>;
|
|
22
|
+
getProctoringSessions(assesseeId: number, params: any): import("rxjs").Observable<Object>;
|
|
23
|
+
getProctoringReportBySession(sessionId: number): import("rxjs").Observable<Object>;
|
|
24
|
+
checkGoogleDriveLinkPublic(googleDriveLink: string): import("rxjs").Observable<Object>;
|
|
20
25
|
static ɵfac: i0.ɵɵFactoryDeclaration<AssessmentTakerService, never>;
|
|
21
26
|
static ɵprov: i0.ɵɵInjectableDeclaration<AssessmentTakerService>;
|
|
22
27
|
}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import { Observable } from 'rxjs';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
/**
|
|
4
|
+
* Thin wrapper around the ProctorLink browser SDK (`@proctorlink/sdk`).
|
|
5
|
+
*
|
|
6
|
+
* The SDK is an OPTIONAL dependency. The library never imports it directly — otherwise every
|
|
7
|
+
* consumer's bundler would have to resolve `@proctorlink/sdk` at build time (and fail when it
|
|
8
|
+
* isn't installed). Instead, a host that uses proctoring passes a `sdkLoader` (e.g.
|
|
9
|
+
* `() => import('@proctorlink/sdk')`) so the module reference lives in the host app, where the
|
|
10
|
+
* package is installed. Consumers who don't use proctoring never reference it and build cleanly.
|
|
11
|
+
*/
|
|
12
|
+
export declare class ProctoringService {
|
|
13
|
+
private session;
|
|
14
|
+
private offHandlers;
|
|
15
|
+
/**
|
|
16
|
+
* Creates a ProctorLink session with the given id + JWT and requests camera access.
|
|
17
|
+
* The returned observable completes once the candidate GRANTS camera access, and errors
|
|
18
|
+
* with `{ code: 'camera_denied' }` if the camera is denied (so the caller can prompt a retry).
|
|
19
|
+
*
|
|
20
|
+
* `refreshToken` is called if the SDK emits `token-expired` (the exam outlived the token): it
|
|
21
|
+
* must return ONLY the new session JWT, which is handed back to the SDK via `updateToken` to
|
|
22
|
+
* resume the same session.
|
|
23
|
+
*/
|
|
24
|
+
start(options: {
|
|
25
|
+
sessionId?: string;
|
|
26
|
+
jwt: string;
|
|
27
|
+
refreshToken?: () => Observable<string>;
|
|
28
|
+
sdkLoader?: () => Promise<any>;
|
|
29
|
+
}): Observable<void>;
|
|
30
|
+
/** Subscribe to the live proctoring event stream. */
|
|
31
|
+
onEvent(cb: (event: any) => void): any;
|
|
32
|
+
/** End capture and flush pending data. */
|
|
33
|
+
stop(): void;
|
|
34
|
+
/** Tear down and remove the camera preview. */
|
|
35
|
+
destroy(params?: {
|
|
36
|
+
endSession: boolean;
|
|
37
|
+
}): void;
|
|
38
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ProctoringService, never>;
|
|
39
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<ProctoringService>;
|
|
40
|
+
}
|
|
@@ -5,6 +5,15 @@ import { AssessmentQuestion } from '../../../shared/interfaces/question.interfac
|
|
|
5
5
|
import * as i0 from "@angular/core";
|
|
6
6
|
export declare class ResponseBuilderService {
|
|
7
7
|
constructor();
|
|
8
|
+
/**
|
|
9
|
+
* Builds the payload used to create the assessee record up front (marked in-progress) so the
|
|
10
|
+
* backend issues a proctoring session / anchors the timer. Optionally carries the captured
|
|
11
|
+
* reference image (base64) for proctoring's first attempt.
|
|
12
|
+
*/
|
|
13
|
+
buildInitAssesseePayload(assesseeResponse: AssessmentInstanceAssesseDTO, assessmentData: AssessmentQuestionPaper, sectionFormGroups: {
|
|
14
|
+
sectionId: number;
|
|
15
|
+
formGroup: FormGroup;
|
|
16
|
+
}[], questionBank: Record<number, AssessmentQuestion>, tenant: number, referenceImageBase64?: string): AssessmentInstanceAssesseDTO;
|
|
8
17
|
buildResponsePayload(assesseeResponse: AssessmentInstanceAssesseDTO, assessmentData: AssessmentQuestionPaper, sectionFormGroups: {
|
|
9
18
|
sectionId: number;
|
|
10
19
|
formGroup: FormGroup;
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
import { EventEmitter, OnDestroy, OnInit } from '@angular/core';
|
|
2
|
+
import { MatDialog } from '@angular/material/dialog';
|
|
3
|
+
import { QuestionBankConfig, QuestionType, RefData } from '../../shared/interfaces/assessment.interface';
|
|
4
|
+
import { AssessmentQuestion } from '../../shared/interfaces/question.interface';
|
|
5
|
+
import { AssessmentBuilderService } from '../assessment-maker/services/assessment-builder.service';
|
|
6
|
+
import { AssessmentMakerService } from '../assessment-maker/services/assessment-maker.service';
|
|
7
|
+
import * as i0 from "@angular/core";
|
|
8
|
+
export declare class QuestionBankComponent implements OnInit, OnDestroy {
|
|
9
|
+
private assessmentMakerService;
|
|
10
|
+
private assessmentBuilderService;
|
|
11
|
+
private dialog;
|
|
12
|
+
labelConfig: {
|
|
13
|
+
[key: string]: string;
|
|
14
|
+
};
|
|
15
|
+
imageConfig: {
|
|
16
|
+
[key: string]: string;
|
|
17
|
+
};
|
|
18
|
+
questionTypes: QuestionType[];
|
|
19
|
+
customRules?: any;
|
|
20
|
+
questionBankConfig: QuestionBankConfig;
|
|
21
|
+
enableSkillsToQuestionMapping: boolean;
|
|
22
|
+
fetchQuestionsList: boolean;
|
|
23
|
+
autoOpenBuilder: boolean;
|
|
24
|
+
headless: boolean;
|
|
25
|
+
questionCreated: EventEmitter<AssessmentQuestion>;
|
|
26
|
+
questionUpdated: EventEmitter<AssessmentQuestion>;
|
|
27
|
+
snackbarMessage: EventEmitter<{
|
|
28
|
+
message: string;
|
|
29
|
+
type: 'success' | 'error' | 'info';
|
|
30
|
+
}>;
|
|
31
|
+
questionsList: AssessmentQuestion[];
|
|
32
|
+
questionBank: Record<number, AssessmentQuestion>;
|
|
33
|
+
configsLoaded: boolean;
|
|
34
|
+
showLoader: boolean;
|
|
35
|
+
rules: any;
|
|
36
|
+
skillsList: RefData[];
|
|
37
|
+
searchTerm: string;
|
|
38
|
+
selectedTypeCode: string;
|
|
39
|
+
currentPage: number;
|
|
40
|
+
pageSize: number;
|
|
41
|
+
totalElements: number;
|
|
42
|
+
hasNext: boolean;
|
|
43
|
+
isLoadingMore: boolean;
|
|
44
|
+
lockedQuestionsMap: Record<number, boolean>;
|
|
45
|
+
private searchSubject$;
|
|
46
|
+
private destroy$;
|
|
47
|
+
constructor(assessmentMakerService: AssessmentMakerService, assessmentBuilderService: AssessmentBuilderService, dialog: MatDialog);
|
|
48
|
+
ngOnInit(): void;
|
|
49
|
+
ngOnDestroy(): void;
|
|
50
|
+
getConfigsFromJSON(): void;
|
|
51
|
+
loadQuestions(page?: number, append?: boolean): void;
|
|
52
|
+
onSearchChange(term: string): void;
|
|
53
|
+
clearSearch(): void;
|
|
54
|
+
onTypeFilterChange(typeCode: string | undefined): void;
|
|
55
|
+
loadMore(): void;
|
|
56
|
+
onQuestionCardClick(question: AssessmentQuestion): void;
|
|
57
|
+
isQuestionLocked(question?: AssessmentQuestion): boolean;
|
|
58
|
+
createEditQuestion(questionDetails?: AssessmentQuestion): void;
|
|
59
|
+
private openBuilderDialog;
|
|
60
|
+
capitalizeFirst(text: string | undefined): string;
|
|
61
|
+
imageErrorHandler(event: any, filePath: string): void;
|
|
62
|
+
getSkillsList(): void;
|
|
63
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<QuestionBankComponent, never>;
|
|
64
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<QuestionBankComponent, "lib-question-bank", never, { "labelConfig": "labelConfig"; "imageConfig": "imageConfig"; "questionTypes": "questionTypes"; "customRules": "customRules"; "questionBankConfig": "questionBankConfig"; "enableSkillsToQuestionMapping": "enableSkillsToQuestionMapping"; "fetchQuestionsList": "fetchQuestionsList"; "autoOpenBuilder": "autoOpenBuilder"; "headless": "headless"; }, { "questionCreated": "questionCreated"; "questionUpdated": "questionUpdated"; "snackbarMessage": "snackbarMessage"; }, never, never>;
|
|
65
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
import * as i1 from "./question-bank.component";
|
|
3
|
+
import * as i2 from "@angular/common";
|
|
4
|
+
import * as i3 from "../../shared/shared.module";
|
|
5
|
+
import * as i4 from "../../shared/material-modules";
|
|
6
|
+
import * as i5 from "@angular/forms";
|
|
7
|
+
import * as i6 from "../assessment-maker/assessment-maker.module";
|
|
8
|
+
export declare class QuestionBankModule {
|
|
9
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<QuestionBankModule, never>;
|
|
10
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<QuestionBankModule, [typeof i1.QuestionBankComponent], [typeof i2.CommonModule, typeof i3.SharedModule, typeof i4.MaterialModules, typeof i5.FormsModule, typeof i5.ReactiveFormsModule, typeof i6.AssessmentMakerModule], [typeof i1.QuestionBankComponent]>;
|
|
11
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<QuestionBankModule>;
|
|
12
|
+
}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { MatDialogRef } from '@angular/material/dialog';
|
|
2
|
+
import { Observable } from 'rxjs';
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
4
|
+
export declare class ConfirmationDialogComponent {
|
|
5
|
+
dialogRef: MatDialogRef<ConfirmationDialogComponent>;
|
|
6
|
+
data: {
|
|
7
|
+
title?: string;
|
|
8
|
+
message?: string;
|
|
9
|
+
note?: string;
|
|
10
|
+
confirmLabel?: string;
|
|
11
|
+
cancelLabel?: string;
|
|
12
|
+
hideCancel?: boolean;
|
|
13
|
+
confirmAction?: () => Observable<any>;
|
|
14
|
+
};
|
|
15
|
+
title: string;
|
|
16
|
+
message: string;
|
|
17
|
+
note: string;
|
|
18
|
+
confirmLabel: string;
|
|
19
|
+
cancelLabel: string;
|
|
20
|
+
hideCancel: boolean;
|
|
21
|
+
loading: boolean;
|
|
22
|
+
errorMessage: string;
|
|
23
|
+
constructor(dialogRef: MatDialogRef<ConfirmationDialogComponent>, data: {
|
|
24
|
+
title?: string;
|
|
25
|
+
message?: string;
|
|
26
|
+
note?: string;
|
|
27
|
+
confirmLabel?: string;
|
|
28
|
+
cancelLabel?: string;
|
|
29
|
+
hideCancel?: boolean;
|
|
30
|
+
confirmAction?: () => Observable<any>;
|
|
31
|
+
});
|
|
32
|
+
onConfirm(): void;
|
|
33
|
+
onCancel(): void;
|
|
34
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ConfirmationDialogComponent, never>;
|
|
35
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<ConfirmationDialogComponent, "lib-confirmation-dialog", never, {}, {}, never, never>;
|
|
36
|
+
}
|
|
@@ -15,6 +15,7 @@ export declare class SkillAllocationComponent implements OnInit {
|
|
|
15
15
|
label: any;
|
|
16
16
|
});
|
|
17
17
|
ngOnInit(): void;
|
|
18
|
+
trackBySkill(index: number, skill: SkillScore): string;
|
|
18
19
|
static ɵfac: i0.ɵɵFactoryDeclaration<SkillAllocationComponent, never>;
|
|
19
20
|
static ɵcmp: i0.ɵɵComponentDeclaration<SkillAllocationComponent, "app-skill-allocation", never, {}, {}, never, never>;
|
|
20
21
|
}
|
|
@@ -1,6 +1,13 @@
|
|
|
1
|
+
export declare const googleDriveController: {
|
|
2
|
+
checkPublic: string;
|
|
3
|
+
};
|
|
1
4
|
export declare const refDataController: {
|
|
2
5
|
getRefDataByCode: string;
|
|
3
6
|
};
|
|
7
|
+
export declare const questionBankController: {
|
|
8
|
+
searchQuestions: string;
|
|
9
|
+
questionsLocked: string;
|
|
10
|
+
};
|
|
4
11
|
export declare const assessmentMakerController: {
|
|
5
12
|
assessmentAndQuestionPaper: string;
|
|
6
13
|
createQuestion: string;
|
|
@@ -10,6 +17,7 @@ export declare const assessmentMakerController: {
|
|
|
10
17
|
duplicateQuestion: string;
|
|
11
18
|
duplicateSection: string;
|
|
12
19
|
createAssessmentInstance: string;
|
|
20
|
+
getResponseCount: string;
|
|
13
21
|
};
|
|
14
22
|
export declare const assessmentTakerController: {
|
|
15
23
|
getAssessmentContextById: string;
|
|
@@ -18,7 +26,12 @@ export declare const assessmentTakerController: {
|
|
|
18
26
|
getChildQuestionsWithIdList: string;
|
|
19
27
|
uploadAttachment: string;
|
|
20
28
|
getAttachments: string;
|
|
21
|
-
|
|
29
|
+
createAssessmentInstanceAssesse: string;
|
|
30
|
+
updateAssessmentInstanceAssesse: string;
|
|
22
31
|
getAnswersByAiaId: string;
|
|
23
32
|
updateMarks: string;
|
|
33
|
+
refreshProctoringToken: string;
|
|
34
|
+
endProctoringSession: string;
|
|
35
|
+
getProctoringSessions: string;
|
|
36
|
+
getProctoringReportBySession: string;
|
|
24
37
|
};
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { AssessmentQuestionPaper } from "./question-paper.interface";
|
|
2
2
|
import { AssessmentQuestion } from "./question.interface";
|
|
3
|
+
import { ProctoringSession } from "./proctoring.interface";
|
|
3
4
|
export interface AssessmentInstance {
|
|
4
5
|
academicSession?: string;
|
|
5
6
|
asmtInstDesc?: LocalizedText[];
|
|
@@ -135,6 +136,8 @@ export interface AssessmentInstanceAssesseDTO {
|
|
|
135
136
|
aiadefaultResponseList?: any[];
|
|
136
137
|
assessmentTaken?: RefData;
|
|
137
138
|
notes?: string | null;
|
|
139
|
+
proctoring?: ProctoringSession;
|
|
140
|
+
createdAt?: number;
|
|
138
141
|
}
|
|
139
142
|
export interface AssessmentStep {
|
|
140
143
|
currentStepIndex: number;
|
|
@@ -164,3 +167,8 @@ export interface SkillScore {
|
|
|
164
167
|
obtainedMarks?: number;
|
|
165
168
|
totalQuestions?: number;
|
|
166
169
|
}
|
|
170
|
+
export interface QuestionBankConfig {
|
|
171
|
+
domain?: string;
|
|
172
|
+
tenant?: number;
|
|
173
|
+
baseLanguage?: string;
|
|
174
|
+
}
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
/** Proctoring session issued to the taker (create/refresh response). */
|
|
2
|
+
export interface ProctoringSession {
|
|
3
|
+
providerSessionId?: string;
|
|
4
|
+
providerSessionJwt?: string;
|
|
5
|
+
providerSessionExpiresAt?: number;
|
|
6
|
+
referenceImageBase64?: string;
|
|
7
|
+
appBaseUrl?: string;
|
|
8
|
+
}
|
|
9
|
+
/** A row in the proctoring-sessions list for an assessee. */
|
|
10
|
+
export interface ProctoringSessionSummary {
|
|
11
|
+
id?: number;
|
|
12
|
+
contextId?: string;
|
|
13
|
+
entityId?: string;
|
|
14
|
+
entityType?: string;
|
|
15
|
+
referenceId?: string;
|
|
16
|
+
provider?: string;
|
|
17
|
+
providerId?: number;
|
|
18
|
+
status?: string;
|
|
19
|
+
isActive?: boolean;
|
|
20
|
+
integrityFlagged?: boolean;
|
|
21
|
+
startedAt?: number;
|
|
22
|
+
endedAt?: number;
|
|
23
|
+
expiresAt?: number;
|
|
24
|
+
validatedAt?: number;
|
|
25
|
+
integritySummary?: IntegritySummary;
|
|
26
|
+
}
|
|
27
|
+
/** The proctoring report for a single session (fetched on demand by session id). */
|
|
28
|
+
export interface ProctoringReport {
|
|
29
|
+
id?: number;
|
|
30
|
+
proctoringSessionId?: number;
|
|
31
|
+
integrityScore?: number;
|
|
32
|
+
integrityLevel?: string;
|
|
33
|
+
integrityFlagged?: boolean;
|
|
34
|
+
identityMatch?: string;
|
|
35
|
+
failureReason?: string;
|
|
36
|
+
isActive?: boolean;
|
|
37
|
+
reportPayload?: string;
|
|
38
|
+
}
|
|
39
|
+
/** A weighted integrity flag inside the report payload. */
|
|
40
|
+
export interface ProctoringReason {
|
|
41
|
+
code?: string;
|
|
42
|
+
detail?: string;
|
|
43
|
+
weight?: number;
|
|
44
|
+
}
|
|
45
|
+
/** A captured evidence frame inside the report payload. */
|
|
46
|
+
export interface ProctoringEvidence {
|
|
47
|
+
seq?: number;
|
|
48
|
+
captured_at?: string;
|
|
49
|
+
is_reference?: boolean;
|
|
50
|
+
source?: string;
|
|
51
|
+
image_url?: string;
|
|
52
|
+
}
|
|
53
|
+
/** A single event in the report payload timeline. */
|
|
54
|
+
export interface ProctoringTimelineEvent {
|
|
55
|
+
type?: string;
|
|
56
|
+
seq?: number;
|
|
57
|
+
at?: string;
|
|
58
|
+
source?: string;
|
|
59
|
+
}
|
|
60
|
+
/** Parsed shape of `ProctoringReport.reportPayload` (a JSON string). */
|
|
61
|
+
export interface ProctoringPayload {
|
|
62
|
+
session_id?: string;
|
|
63
|
+
status?: string;
|
|
64
|
+
external_user_id?: string;
|
|
65
|
+
exam_id?: string;
|
|
66
|
+
attempt_id?: string;
|
|
67
|
+
started_at?: string;
|
|
68
|
+
ended_at?: string;
|
|
69
|
+
validated_at?: string;
|
|
70
|
+
duration_seconds?: number;
|
|
71
|
+
integrity?: {
|
|
72
|
+
score?: number;
|
|
73
|
+
level?: string;
|
|
74
|
+
flagged?: boolean;
|
|
75
|
+
analysis_complete?: boolean;
|
|
76
|
+
identity_match?: string;
|
|
77
|
+
reasons?: ProctoringReason[];
|
|
78
|
+
};
|
|
79
|
+
face_analysis?: {
|
|
80
|
+
frames_checked?: number;
|
|
81
|
+
no_face_frames?: number;
|
|
82
|
+
multi_face_frames?: number;
|
|
83
|
+
impersonation_frames?: number;
|
|
84
|
+
};
|
|
85
|
+
activity?: {
|
|
86
|
+
total_frames?: number;
|
|
87
|
+
total_events?: number;
|
|
88
|
+
flagged_events?: number;
|
|
89
|
+
by_type?: {
|
|
90
|
+
[key: string]: number;
|
|
91
|
+
};
|
|
92
|
+
};
|
|
93
|
+
evidence?: ProctoringEvidence[];
|
|
94
|
+
timeline?: ProctoringTimelineEvent[];
|
|
95
|
+
}
|
|
96
|
+
export interface IntegritySummary {
|
|
97
|
+
proctoringSessionId?: number;
|
|
98
|
+
integrityScore?: number;
|
|
99
|
+
integrityLevel?: string;
|
|
100
|
+
integrityFlagged?: boolean;
|
|
101
|
+
}
|
|
@@ -6,15 +6,12 @@ import * as i4 from "@angular/cdk/drag-drop";
|
|
|
6
6
|
import * as i5 from "@angular/material/menu";
|
|
7
7
|
import * as i6 from "@angular/material/dialog";
|
|
8
8
|
import * as i7 from "@angular/material/tooltip";
|
|
9
|
-
import * as i8 from "@angular/material/
|
|
10
|
-
import * as i9 from "@angular/
|
|
11
|
-
import * as i10 from "@angular/material/
|
|
12
|
-
import * as i11 from "@angular/material/
|
|
13
|
-
import * as i12 from "@angular/cdk/overlay";
|
|
14
|
-
import * as i13 from "@angular/material/datepicker";
|
|
15
|
-
import * as i14 from "@angular/material/core";
|
|
9
|
+
import * as i8 from "@angular/material/tabs";
|
|
10
|
+
import * as i9 from "@angular/cdk/overlay";
|
|
11
|
+
import * as i10 from "@angular/material/datepicker";
|
|
12
|
+
import * as i11 from "@angular/material/core";
|
|
16
13
|
export declare class MaterialModules {
|
|
17
14
|
static ɵfac: i0.ɵɵFactoryDeclaration<MaterialModules, never>;
|
|
18
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<MaterialModules, never, [typeof i1.MatProgressSpinnerModule, typeof i2.MatExpansionModule, typeof i3.MatSelectModule, typeof i4.DragDropModule, typeof i5.MatMenuModule, typeof i6.MatDialogModule, typeof i7.MatTooltipModule, typeof i8.
|
|
15
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<MaterialModules, never, [typeof i1.MatProgressSpinnerModule, typeof i2.MatExpansionModule, typeof i3.MatSelectModule, typeof i4.DragDropModule, typeof i5.MatMenuModule, typeof i6.MatDialogModule, typeof i7.MatTooltipModule, typeof i8.MatTabsModule, typeof i9.OverlayModule, typeof i10.MatDatepickerModule, typeof i11.MatNativeDateModule], [typeof i1.MatProgressSpinnerModule, typeof i2.MatExpansionModule, typeof i3.MatSelectModule, typeof i4.DragDropModule, typeof i5.MatMenuModule, typeof i6.MatDialogModule, typeof i7.MatTooltipModule, typeof i8.MatTabsModule, typeof i9.OverlayModule, typeof i10.MatDatepickerModule, typeof i11.MatNativeDateModule]>;
|
|
19
16
|
static ɵinj: i0.ɵɵInjectorDeclaration<MaterialModules>;
|
|
20
17
|
}
|
|
@@ -2,11 +2,12 @@ import * as i0 from "@angular/core";
|
|
|
2
2
|
import * as i1 from "./components/text-editor/text-editor.component";
|
|
3
3
|
import * as i2 from "./pipes/order-by.pipe";
|
|
4
4
|
import * as i3 from "./components/skill-allocation/skill-allocation.component";
|
|
5
|
-
import * as i4 from "
|
|
6
|
-
import * as i5 from "@angular/
|
|
7
|
-
import * as i6 from "
|
|
5
|
+
import * as i4 from "./components/confirmation-dialog/confirmation-dialog.component";
|
|
6
|
+
import * as i5 from "@angular/common";
|
|
7
|
+
import * as i6 from "@angular/forms";
|
|
8
|
+
import * as i7 from "./material-modules";
|
|
8
9
|
export declare class SharedModule {
|
|
9
10
|
static ɵfac: i0.ɵɵFactoryDeclaration<SharedModule, never>;
|
|
10
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<SharedModule, [typeof i1.TextEditorComponent, typeof i2.OrderByPipe, typeof i3.SkillAllocationComponent], [typeof
|
|
11
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<SharedModule, [typeof i1.TextEditorComponent, typeof i2.OrderByPipe, typeof i3.SkillAllocationComponent, typeof i4.ConfirmationDialogComponent], [typeof i5.CommonModule, typeof i6.FormsModule, typeof i6.ReactiveFormsModule, typeof i7.MaterialModules], [typeof i1.TextEditorComponent, typeof i3.SkillAllocationComponent, typeof i4.ConfirmationDialogComponent, typeof i7.MaterialModules, typeof i2.OrderByPipe]>;
|
|
11
12
|
static ɵinj: i0.ɵɵInjectorDeclaration<SharedModule>;
|
|
12
13
|
}
|
package/lib/shared/utils.d.ts
CHANGED
|
@@ -1,3 +1,7 @@
|
|
|
1
1
|
export declare function deepClone<T>(data: T): T;
|
|
2
2
|
export declare function generateUuid(): string;
|
|
3
3
|
export declare function sortByOrder(list: any[] | undefined | null, property?: string, order?: 'asc' | 'desc'): any[];
|
|
4
|
+
/**
|
|
5
|
+
* Recursively removes a specified key (default: 'uuid') from any object or array structure.
|
|
6
|
+
*/
|
|
7
|
+
export declare function removeKeyDeep<T>(obj: T, keyToRemove?: string): T;
|
package/package.json
CHANGED
package/public-api.d.ts
CHANGED
|
@@ -3,7 +3,10 @@ export * from './lib/shared/interfaces/question.interface';
|
|
|
3
3
|
export * from './lib/shared/interfaces/question-paper.interface';
|
|
4
4
|
export * from './lib/modules/assessment-taker/assessment-taker.module';
|
|
5
5
|
export * from './lib/modules/assessment-maker/assessment-maker.module';
|
|
6
|
+
export * from './lib/modules/question-bank/question-bank.module';
|
|
6
7
|
export * from './lib/commons-assessment.module';
|
|
7
8
|
export * from './lib/modules/assessment-maker/assessment-maker.component';
|
|
9
|
+
export * from './lib/modules/assessment-maker/components/assessment-builder/assessment-builder.component';
|
|
8
10
|
export * from './lib/modules/assessment-taker/assessment-taker.component';
|
|
11
|
+
export * from './lib/modules/question-bank/question-bank.component';
|
|
9
12
|
export * from './lib/shared/utils';
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<g clip-path="url(#clip0_13706_60051)">
|
|
3
|
+
<path d="M14 3V7C14 7.26522 14.1054 7.51957 14.2929 7.70711C14.4804 7.89464 14.7348 8 15 8H19" stroke="#4D89EB" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
|
|
4
|
+
<path d="M5 13V5C5 4.46957 5.21071 3.96086 5.58579 3.58579C5.96086 3.21071 6.46957 3 7 3H14L19 8V19C19 19.5304 18.7893 20.0391 18.4142 20.4142C18.0391 20.7893 17.5304 21 17 21H11.5M2 19H9M6 22L9 19L6 16" stroke="#4D89EB" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
|
|
5
|
+
</g>
|
|
6
|
+
<defs>
|
|
7
|
+
<clipPath id="clip0_13706_60051">
|
|
8
|
+
<rect width="24" height="24" fill="white"/>
|
|
9
|
+
</clipPath>
|
|
10
|
+
</defs>
|
|
11
|
+
</svg>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M12 5V19M5 12H19" stroke="#FFFFFF" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/></svg>
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
|
|
2
|
+
<path fill="#467DD6" d="M12 4.5C7 4.5 2.7 7.6 1 12c1.7 4.4 6 7.5 11 7.5s9.3-3.1 11-7.5c-1.7-4.4-6-7.5-11-7.5Zm0 12.5a5 5 0 1 1 0-10 5 5 0 0 1 0 10Zm0-2a3 3 0 1 0 0-6 3 3 0 0 0 0 6Z"/>
|
|
3
|
+
</svg>
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"COMMONS_ASSESSMENT.ICON.NO_QUESTIONS": "assets/commons-assessment/images/no-questions.svg",
|
|
3
3
|
"COMMONS_ASSESSMENT.ICON.PLUS_PRIMARY": "assets/commons-assessment/images/plus-primary.svg",
|
|
4
|
+
"COMMONS_ASSESSMENT.ICON.PLUS_WHITE": "assets/commons-assessment/images/plus-white.svg",
|
|
4
5
|
"COMMONS_ASSESSMENT.ICON.KEYBOARD": "assets/commons-assessment/images/keyboard.svg",
|
|
5
6
|
"COMMONS_ASSESSMENT.ICON.DRAG_DROP": "assets/commons-assessment/images/drag-drop.svg",
|
|
6
7
|
"COMMONS_ASSESSMENT.ICON.ACTION_DOTS": "assets/commons-assessment/images/action-dots.svg",
|
|
@@ -20,5 +21,10 @@
|
|
|
20
21
|
"COMMONS_ASSESSMENT.ICON.SVG": "assets/commons-assessment/images/svg.svg",
|
|
21
22
|
"COMMONS_ASSESSMENT.ICON.DEFAULT_FILE": "assets/commons-assessment/images/file.svg",
|
|
22
23
|
"COMMONS_ASSESSMENT.ICON.CROSS_RED": "assets/commons-assessment/images/cross-red.svg",
|
|
23
|
-
"COMMONS_ASSESSMENT.ICON.CHECK_GREEN": "assets/commons-assessment/images/check-green.svg"
|
|
24
|
+
"COMMONS_ASSESSMENT.ICON.CHECK_GREEN": "assets/commons-assessment/images/check-green.svg",
|
|
25
|
+
"COMMONS_ASSESSMENT.ICON.PROCTORING": "assets/commons-assessment/images/proctoring.svg",
|
|
26
|
+
"COMMONS_ASSESSMENT.ICON.USER": "assets/commons-assessment/images/user.svg",
|
|
27
|
+
"COMMONS_ASSESSMENT.ICON.ARROW_DOWN_BLUE": "assets/commons-assessment/images/arrow-down-blue.svg",
|
|
28
|
+
"COMMONS_ASSESSMENT.ICON.ARROW_UP_BLUE": "assets/commons-assessment/images/arrow-up-blue.svg",
|
|
29
|
+
"COMMONS_ASSESSMENT.ICON.FILE_IMPORT": "assets/commons-assessment/images/file-import.svg"
|
|
24
30
|
}
|