From 4524eec6c7a2a401bf533af46a263fea4986b2de Mon Sep 17 00:00:00 2001 From: Anshul Sharma Date: Tue, 23 Mar 2021 06:01:44 +0100 Subject: [PATCH 1/2] feature: add review mode flag for PCIs --- package-lock.json | 2 +- package.json | 2 +- .../renderers/interactions/PortableCustomInteraction.js | 7 +++++-- 3 files changed, 7 insertions(+), 4 deletions(-) diff --git a/package-lock.json b/package-lock.json index 1a4b3766..0bd03489 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "@oat-sa/tao-item-runner-qti", - "version": "0.20.0", + "version": "0.21.0", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/package.json b/package.json index 2502baf5..586d6b5b 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@oat-sa/tao-item-runner-qti", - "version": "0.20.0", + "version": "0.21.0", "displayName": "TAO Item Runner QTI", "description": "TAO QTI Item Runner modules", "files": [ diff --git a/src/reviewRenderer/renderers/interactions/PortableCustomInteraction.js b/src/reviewRenderer/renderers/interactions/PortableCustomInteraction.js index 9e3c477b..839e4a38 100644 --- a/src/reviewRenderer/renderers/interactions/PortableCustomInteraction.js +++ b/src/reviewRenderer/renderers/interactions/PortableCustomInteraction.js @@ -30,6 +30,9 @@ const getData = (customInteraction, data) => { let markup = data.markup; const isInteractionDisabled = isInteractionDisabledForPci(data.typeIdentifier); + // Set review mode on for PCI + customInteraction.properties.isReviewMode = true; + //remove ns + fix media file path markup = util.removeMarkupNamespaces(markup); markup = PortableElement.fixMarkupMediaSources(markup, this); @@ -39,8 +42,8 @@ const getData = (customInteraction, data) => { /** * Set back response for review mode - * @param {Object} interaction - * @param {Object} serializedState + * @param {Object} interaction + * @param {Object} serializedState */ const setState = (interaction, serializedState) => { const pciRenderer = interaction.data('pci-renderer'); From 7df670bb0ca5a36384aa7defa690693149597166 Mon Sep 17 00:00:00 2001 From: Anshul Sharma Date: Thu, 25 Mar 2021 07:49:41 +0100 Subject: [PATCH 2/2] chore: remove version bump --- package-lock.json | 2 +- package.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/package-lock.json b/package-lock.json index 0bd03489..1a4b3766 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "@oat-sa/tao-item-runner-qti", - "version": "0.21.0", + "version": "0.20.0", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/package.json b/package.json index 586d6b5b..2502baf5 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@oat-sa/tao-item-runner-qti", - "version": "0.21.0", + "version": "0.20.0", "displayName": "TAO Item Runner QTI", "description": "TAO QTI Item Runner modules", "files": [