From 17dc6f855fa907513588204b81c6003a92ac5330 Mon Sep 17 00:00:00 2001 From: Benoit Rospars <benoit.rospars@inria.fr> Date: Fri, 25 Oct 2024 10:42:15 +0200 Subject: [PATCH] Rename explanation to feedback and remove deprecated easierScoring property --- src/v1/epoc.ts | 1 - src/v1/question.ts | 14 ++++++++++++-- src/v2/question.ts | 16 ++++++++++++++++ 3 files changed, 28 insertions(+), 3 deletions(-) diff --git a/src/v1/epoc.ts b/src/v1/epoc.ts index ea65552..2c0ce08 100644 --- a/src/v1/epoc.ts +++ b/src/v1/epoc.ts @@ -49,6 +49,5 @@ export interface Chapter { export interface Parameters { chapterParameter?: string; - easierScoring?: boolean; openQuestionButton?: string; } diff --git a/src/v1/question.ts b/src/v1/question.ts index 9406182..919c9e4 100644 --- a/src/v1/question.ts +++ b/src/v1/question.ts @@ -7,8 +7,17 @@ export interface Question { label: string; responses: Array<Response>; correctResponse: string|Array<string>|Array<{label: string, values: string[]}>; + + /** + * The explanation of the correction of the question + * @deprecated use feedback property + */ explanation: html; - easierScoring?: boolean; + + /** + * The global feedback of the question + */ + feedback: html; } export interface DragAndDropquestion extends Question{ @@ -49,5 +58,6 @@ export interface CustomQuestion extends Question { export interface Response { label: string; value: string; - explanation?: string; + feedback?: string; + score?:number; } \ No newline at end of file diff --git a/src/v2/question.ts b/src/v2/question.ts index 7181b48..8363685 100644 --- a/src/v2/question.ts +++ b/src/v2/question.ts @@ -37,8 +37,14 @@ export interface Question { /** * The explanation of the correction of the question + * @deprecated use feedback property */ explanation: html; + + /** + * The global feedback of the question + */ + feedback: html; } /** @@ -54,6 +60,16 @@ export interface Response { * The hidden value of the response */ value: string; + + /** + * The feedback of this specific response + */ + feedback?: string; + + /** + * The partial score of this particular response. If set the question total score is based on the sum of partial scores + */ + score?: number } /** -- GitLab