From 35790c91b64db9d90866bd73769c602587b43b0c Mon Sep 17 00:00:00 2001 From: Andrey Shaveko Date: Mon, 28 Aug 2023 19:02:51 +0200 Subject: [PATCH] chore: add bundles --- views/js/loader/qtiLoader.min.js.map | 2 +- views/js/loader/taoQtiItem.min.js | 2 +- views/js/loader/taoQtiItem.min.js.map | 2 +- views/js/loader/taoQtiItemRunner.es5.min.js.map | 2 +- views/js/loader/taoQtiItemRunner.min.js.map | 2 +- views/js/qtiCreator/widgets/static/helpers/comments.js | 7 +------ 6 files changed, 6 insertions(+), 11 deletions(-) diff --git a/views/js/loader/qtiLoader.min.js.map b/views/js/loader/qtiLoader.min.js.map index 6e7cb1b448..17715e409d 100644 --- a/views/js/loader/qtiLoader.min.js.map +++ b/views/js/loader/qtiLoader.min.js.map @@ -1 +1 @@ -{"version":3,"names":["loaderScript","document","getElementById","configUrl","getAttribute","bundle","loadController","controllerOptions","controllerPath","params","JSON","parse","err","window","require","controller","startController","started","start","addEventListener","readyState","loadBundles","loaded","bundles","concat","filter","item","index","indexOf","forEach","length","define","qtiClasses","_container","assessmentItem","responseProcessing","_simpleFeedbackRule","stylesheet","math","figure","img","figcaption","object","outcomeDeclaration","responseDeclaration","rubricBlock","associableHotspot","gap","gapImg","gapText","hotspotChoice","hottext","inlineChoice","simpleAssociableChoice","simpleChoice","associateInteraction","choiceInteraction","endAttemptInteraction","extendedTextInteraction","gapMatchInteraction","graphicAssociateInteraction","graphicGapMatchInteraction","graphicOrderInteraction","hotspotInteraction","hottextInteraction","inlineChoiceInteraction","matchInteraction","mediaInteraction","orderInteraction","prompt","selectPointInteraction","sliderInteraction","textEntryInteraction","uploadInteraction","feedbackBlock","feedbackInline","modalFeedback","customInteraction","infoControl","include","table","printedVariable","_tooltip","_","Object","prototype","hasOwnProperty","call","util","buildSerial","prefix","id","chars","i","charAt","Math","floor","random","buildId","usedIds","suffix","exists","TypeError","getUsedIds","contains","buildIdentifier","useSuffix","getUsedIdentifiers","isUndefined","replace","findInCollection","element","collectionNames","searchedSerial","found","isString","isArray","each","collectionName","collection","split","nameToken","elt","parent","isFunction","find","Error","addMarkupNamespace","markup","ns","$0","$1","$2","$3","$4","removeMarkupNamespaces","removeMarkupNamespace","getMarkupUsedNamespaces","namespaces","original","slash","node","push","uniq","$","rendererConfigHelper","getOptionsFromArguments","args","options","data","placeholder","subclass","renderer","arg","isRenderer","isPlainObject","console","log","_class","loggerFactory","rendererConfig","_instances","logger","Element","Class","extend","qtiClass","serial","rootElement","init","attributes","metaData","match","setAttributes","initContainer","arguments","initObject","is","getSerial","elts","getComposingElements","attr","name","value","prop","trigger","key","removeData","removeAttr","removeAttributes","warn","getAttributes","clone","attrNames","append","getBody","getObject","v","isA","getUsedClasses","ret","composingElts","body","location","getRootElement","setRelatedItem","setRootElement","getRelatedItem","setRenderer","getRenderer","render","rendering","_renderer","tplData","defaultData","tag","resolveUrl","merge","getData","renderTpl","replaceWith","postRender","altClassName","postRenderers","compact","getContainer","$scope","toArray","arr","type","isEmpty","addClass","className","clazz","_containClass","hasClass","removeClass","regex","RegExp","trim","toggleClass","state","isset","issetElement","unset","unsetElement","allClassStr","test","qtiElement","getElementBySerial","composingElements","getPrefix","html5Ns","prefixed","xmlNsHandler","stripNs","pattern","openRegEx","closeRegEx","restoreNs","xml","ignoreMarkup","xmlCopy","xmlRe","tagRe","xmlMatch","imsXsd","prefixAtt","tagMatch","responseRules","MATCH_CORRECT","responseIdentifier","outcomeIdentifier","responseIf","expression","expressions","identifier","baseType","MAP_RESPONSE","MAP_RESPONSE_POINT","responseRulesHelper","_templateNames","NONE","response","isUsingTemplate","tpl","template","isValidTemplateName","tplName","getTemplateUriFromName","getTemplateNameFromUri","tplUri","forIn","uri","getTemplateNameFromResponseRules","outcomeRules","keys","isEqual","itemScore","responseIdentifiers","outcomeExpressions","map","moduleLoader","responseHelper","itemScoreHelper","loadPortableCustomElementProperties","portableElement","rawProperties","properties","forOwn","e","loadPortableCustomElementData","typeIdentifier","entryPoint","libraries","setNamespace","xmlns","Loader","classesLocation","qti","setClassesLocation","qtiClassesList","getRequiredClasses","union","loadRequiredClasses","callback","reload","requiredClass","requiredClasses","required","module","category","addList","load","then","loadeded","QtiClass","getLoadedClasses","loadItemData","Qti","loadContainer","outcomes","outcome","buildOutcome","addOutcomeDeclaration","feedbacks","feedback","buildElement","addModalFeedback","stylesheets","addStylesheet","responses","responseRuleItemIndex","findIndex","_ref","responseRule","splice","buildResponse","addResponseDeclaration","feedbackRules","fbData","feedbackOutcomeIdentifier","feedbackOutcome","buildSimpleFeedbackRule","feedbackResponseRuleIndex","_ref2","setOutcomeResponseRule","responseKey","customResponseProcessing","some","setResponseProcessing","buildResponseProcessing","setNamespaces","setSchemaLocations","schemaLocations","setApipAccessibility","apipAccessibility","loadAndBuildElement","loadElement","loadElementData","loadElements","allElements","elementData","howMatch","defaultValue","correctResponse","correctResponses","mapEntries","size","mapping","areaMapping","mappingAttributes","feedbackRule","setCondition","condition","comparedValue","feedbackThen","modalFeedbacks","feedbackElse","comparedOutcome","rp","processingType","bodyObject","bodyData","elements","defaults","eltData","setElement","text","bdy","loadObjectData","loadInteractionData","loadChoiceData","loadMathData","loadPicData","loadTooltipData","interaction","buildInteractionChoices","loadPciData","choices","set","matchSet","choice","addChoice","gapImgs","addGapImg","val","_alt","setMathML","mathML","annotations","encoding","setAnnotation","tooltip","content","pci","pic","getRawValues","pciVar","base","values","list","_checkContainerType","_getBodyDom","html","_setBodyDomClass","newClass","oldClass","$wrapper","_setDomClass","$bodyDom","wrapInner","setEncodedDataToDom","dataName","newValue","oldValue","_getEncodedDataString","setEncodedData","getEncodedData","removeEncodedData","hasEncodedData","$body","matches","_prefix","container","$$1","context","containerHelper","Handlebars","Helpers0","iframeNotifier","previewOkBtn","asString","Template","deliveryOkBtn","Template$1","showFeedbacks","loader","itemSession","onCloseCallback","onShowCallback","firstFeedback","interactionsDisplayInfo","getInteractionsDisplayInfo","messages","renderedFeebacks","renderingQueue","$itemContainer","$itemBody","children","feedbackIds","message","$container","_currentMessageGroupId","interactionInfo","order","getFeedbackMessageSignature","displayContainer","messageGroupId","sortBy","clearModalFeedbacks","renderingToken","renderModalFeedback","renderingData","dom","on","autoscroll","replaceControl","getQtiContainer","me","max","__knownParent__","currentScrollTop","minScrollTop","maxScrollTop","scrollTop","$element","offset","top","height","outerHeight","min","animate","extractDisplayInfo","$displayContainer","$interactionContainer","closest","uniqueId","interactionContainer","interactionOrder","_interactionInfo","remove","renderedCallback","$modalFeedback","inline","done","Promise","race","all","pop","resolve","reject","delay","timeout","catch","$controls","$toggleContainer","parents","initControlToggle","toggleButtonTemplate","$ok","click","fb","hide","uncover","show","cover","interactionContainers","$cover","$interaction","toLowerCase","__initialized","depth0","helpers","partials","compilerInfo","helper","buffer","helperMissing","escapeExpression","__","hash","inlineRenderer","async","count","feedbacksToBeDisplayed","callstack","eachRight","endCallback","cb","series","closeCallback","$feedback","$feedbackBox","modal","modalRenderer","ItemLoader","modalFeedbackInline","modalFeedbackModal","QtiRunner","rpEngine","itemApi","updateItemApi","getResponses","states","getStates","variables","property","file","mime","setVariables","saveResponses","resultApi","setQtiRunner","setItemApi","that","oldStateVariables","stringify","stateVariables","onKill","killCallback","newStateVariables","serviceApi","getHasBeenPaused","submit","setHasBeenPaused","getLoader","self","renderItem","noop","initInteractionsResponse","listenForThemeChange","interactions","getInteractions","responseId","getVariable","setState","setVariable","off","themeName","themeLoader","getThemeLoader","originalEvent","detail","change","validate","finish","getResponse","error","getState","inlineDisplay","config","inlineModalFeedback","_Mathfloor","interactionHelper","convertChoices","outputType","_this","c","findChoices","inputType","getChoice","getChoiceByIdentifier","shuffleChoices","r","f","j","n","k","tmp","serialToIdentifier","choiceSerial","themesHelper","getDocumentBaseUrl","protocol","host","pathname","hb","compile","_renderableClasses","_dependencies","_renderableSubclasses","_defaults","_isValidRenderer","valid","classCorrect","pos","slice","subClass","Renderer","registerRendererClass","success","_locations","_renderers","shuffledChoices","_getClassRenderer","setOption","setOptions","opts","getOption","getCustomMessage","elementName","messageKey","getAssetManager","assetManager","qtiSubclass","res","decorators","isObject","before","after","renderDirect","setResponse","qtiInteraction","resetResponse","destroy","getLoadedRenderers","register","renderersLocations","themeData","getCurrentThemeData","themes","available","theme","path","preload","intersection","reqClass","deps","requiredSubClasses","unload","setShuffledChoices","identificationType","pluck","getShuffledChoices","reshuffle","returnedType","getChoices","getRenderers","getLocations","url","getAbsoluteUrl","relUrl","absUrl","runtimeLocations","runtimeLocation","baseUrl","setAreaBroker","areaBroker","_areaBroker","getAreaBroker","getItemCreator","Renderer$1","build","defaultOptions","NewRenderer","apply","eventifier","_requirejs","_defaultLoadingOptions","loadModuleConfig","manifest","requireConfigAliases","reqConfigs","modules","runtime","pciConfig","paths","runtimeModules","model","reduce","acc","conf","isPortableElementProvider","provider","portableElementRegistry","methods","_loaded","__providers","_registry","get","version","last","registerProvider","moduleName","resetProviders","loadProviders","loadPromise","providerLoadingStack","shift","getAllVersions","versions","getRuntime","assign","label","getCreator","creator","getLatestCreators","lastVersion","hook","enabled","getBaseUrl","loadRuntimes","providers","loadStack","results","configLoadingStack","_pcis","moduleConfigs","loadCreators","requiredCreatorHooks","portableElementModel","creators","creatorHook","getTypeIdentifier","enable","disable","isEnabled","featuresService","QtiElements","classes","itemBody","abstract","atomicBlock","atomicInline","simpleBlock","simpleInline","flowStatic","blockStatic","inlineStatic","flow","tableCell","caption","xhtml","col","colgroup","div","dl","dt","dd","hr","li","ol","ul","param","tbody","tfoot","thead","td","th","tr","a","abbr","acronym","b","big","cite","code","dfn","em","kbd","q","samp","small","span","strong","sub","sup","tt","var","blockquote","address","h1","h2","h3","h4","h5","h6","p","pre","br","textRun","blockInteraction","inlineInteraction","templateElement","templateBlock","templateInline","drawingInteraction","graphicInteraction","cache","containable","getAllowedContainersElements","getAllowedContainers","jqSelector","substring","getParentClasses","aClass","intersect","getChildClasses","getAllowedContents","recursive","checked","contain","child","isAllowedClass","qtiContainerClass","qtiContentClass","allowedClasses","cacheType","isBlock","isInline","topClass","isVisible","getAvailableAuthoringElements","tagTitles","commonInteractions","inlineInteractions","graphicInteractions","authoringElements","description","icon","short","tags","group","availableElements","elementId","entries","qtiElements","customInteractionRegistry","getAuthoringData","enabledOnly","pciModel","ciRegistry","registry","infoControlRegistry","icRegistry","getBaseUrlByIdentifier","handle","handlePortableElementLocation","source","relative","fullmatch","relPath","assetManagerFactory","assetStrategies","portableAssetStrategy","itemThemes","moduleConfig","handleTheme","root_url","toString","taomedia","external","base64","itemCssNoCache","locations","\"simpleChoice.choiceInteraction\"","\"simpleChoice.orderInteraction\"","\"simpleAssociableChoice.matchInteraction\"","\"simpleAssociableChoice.associateInteraction\"","enableDragAndDrop","associate","associateDragAndDrop","gapMatch","gapMatchDragAndDrop","graphicGapMatch","graphicGapMatchDragAndDrop","orderDragAndDrop","userModules","dependency","exec","history","fixBrokenBrowsers","bootstrap","runnerContext","onItemApiReady","qtiRunner","coreItemData","itemData","variableElementsData","variableElements","contentVariables","userModulesOverride","userScripts","userVars","defer","focus","qtiBootstrap","tao","qtiRunnerContext"],"sources":["/github/workspace/tao/views/build/config-wrap-start-default.js","../../loader/bootstrap.js","../qtiItem/core/qtiClasses.js","../qtiItem/helper/util.js","../qtiItem/helper/rendererConfig.js","../qtiItem/core/Element.js","../qtiItem/helper/xmlNsHandler.js","../qtiItem/helper/responseRules.js","../qtiItem/helper/response.js","../qtiItem/helper/itemScore.js","../qtiItem/core/Loader.js","../qtiItem/helper/pci.js","../qtiItem/helper/container.js","../qtiRunner/modalFeedback/inlineRenderer.js","../qtiRunner/modalFeedback/modalRenderer.js","../qtiRunner/core/QtiRunner.js","../qtiItem/helper/interactionHelper.js","../qtiRunner/core/Renderer.js","../portableElementRegistry/factory/factory.js","../qtiCreator/helper/qtiElements.js","../portableElementRegistry/factory/ciRegistry.js","../portableElementRegistry/ciRegistry.js","../portableElementRegistry/factory/icRegistry.js","../portableElementRegistry/icRegistry.js","../portableElementRegistry/assetManager/portableAssetStrategy.js","../qtiCommonRenderer/renderers/config.js","../qtiCommonRenderer/renderers/Renderer.js","../runner/provider/manager/userModules.js","../runtime/qtiBootstrap.js","../runtime/qtiLoader.js","module-create.js","/github/workspace/tao/views/build/config-wrap-end-default.js"],"sourcesContent":["\n","/**\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2016-2018 (original work) Open Assessment Technologies SA ;\n */\n\n/**\n * Bootstrap the app, start the entry controller\n * @author Bertrand Chevrier \n */\n(function(){\n 'use strict';\n\n\n\n var loaderScript = document.getElementById('amd-loader');\n var configUrl = loaderScript.getAttribute('data-config');\n var bundle = loaderScript.getAttribute('data-bundle');\n\n var loadController = function loadController(){\n var controllerOptions = {};\n var controllerPath = loaderScript.getAttribute('data-controller');\n var params = loaderScript.getAttribute('data-params');\n try{\n controllerOptions = JSON.parse(params);\n } catch(err){\n controllerOptions = {};\n }\n window.require([controllerPath], function(controller) {\n var startController = function startController(){\n if(!window.started){\n window.started = true;\n controller.start(controllerOptions);\n }\n };\n document.addEventListener('readystatechange', startController, false);\n if (document.readyState === 'complete') {\n startController();\n }\n });\n };\n\n //always start to load the config\n window.require([configUrl], function() {\n\n //define the global loading mechanism\n if(!window.loadBundles){\n //keep tracl of loaded bundles, even if require does it,\n //this prevent some unecessary cycles\n window.loaded = {};\n\n /**\n * Loading entry point for inter bundle dependency,\n * always take the bundles from the params and window.bundles\n * @param {String[]} [bundles] - an optional list of bundle to load\n */\n window.loadBundles = function loadBundles(bundles){\n bundles = bundles || [];\n bundles = bundles.concat(window.bundles)\n bundles = bundles.filter( function(item, index){\n return item && bundles.indexOf(item) === index && window.loaded[item] !== true;\n });\n require(bundles, function(){\n bundles.forEach( function( item ) {\n window.loaded[item] = true;\n });\n loadController();\n });\n }\n }\n\n if(bundle || (window.bundles && window.bundles.length)) {\n window.loadBundles([bundle]);\n } else {\n loadController();\n }\n });\n})();\n\ndefine(\"loader/bootstrap\", function(){});\n\n","define('taoQtiItem/qtiItem/core/qtiClasses',[],function () { 'use strict';\n\n var qtiClasses = {\n _container: 'taoQtiItem/qtiItem/core/Container',\n assessmentItem: 'taoQtiItem/qtiItem/core/Item',\n responseProcessing: 'taoQtiItem/qtiItem/core/ResponseProcessing',\n _simpleFeedbackRule: 'taoQtiItem/qtiItem/core/response/SimpleFeedbackRule',\n stylesheet: 'taoQtiItem/qtiItem/core/Stylesheet',\n math: 'taoQtiItem/qtiItem/core/Math',\n figure: 'taoQtiItem/qtiItem/core/Figure',\n img: 'taoQtiItem/qtiItem/core/Img',\n figcaption: 'taoQtiItem/qtiItem/core/Figcaption',\n object: 'taoQtiItem/qtiItem/core/Object',\n outcomeDeclaration: 'taoQtiItem/qtiItem/core/variables/OutcomeDeclaration',\n responseDeclaration: 'taoQtiItem/qtiItem/core/variables/ResponseDeclaration',\n rubricBlock: 'taoQtiItem/qtiItem/core/RubricBlock',\n associableHotspot: 'taoQtiItem/qtiItem/core/choices/AssociableHotspot',\n gap: 'taoQtiItem/qtiItem/core/choices/Gap',\n gapImg: 'taoQtiItem/qtiItem/core/choices/GapImg',\n gapText: 'taoQtiItem/qtiItem/core/choices/GapText',\n hotspotChoice: 'taoQtiItem/qtiItem/core/choices/HotspotChoice',\n hottext: 'taoQtiItem/qtiItem/core/choices/Hottext',\n inlineChoice: 'taoQtiItem/qtiItem/core/choices/InlineChoice',\n simpleAssociableChoice: 'taoQtiItem/qtiItem/core/choices/SimpleAssociableChoice',\n simpleChoice: 'taoQtiItem/qtiItem/core/choices/SimpleChoice',\n associateInteraction: 'taoQtiItem/qtiItem/core/interactions/AssociateInteraction',\n choiceInteraction: 'taoQtiItem/qtiItem/core/interactions/ChoiceInteraction',\n endAttemptInteraction: 'taoQtiItem/qtiItem/core/interactions/EndAttemptInteraction',\n extendedTextInteraction: 'taoQtiItem/qtiItem/core/interactions/ExtendedTextInteraction',\n gapMatchInteraction: 'taoQtiItem/qtiItem/core/interactions/GapMatchInteraction',\n graphicAssociateInteraction: 'taoQtiItem/qtiItem/core/interactions/GraphicAssociateInteraction',\n graphicGapMatchInteraction: 'taoQtiItem/qtiItem/core/interactions/GraphicGapMatchInteraction',\n graphicOrderInteraction: 'taoQtiItem/qtiItem/core/interactions/GraphicOrderInteraction',\n hotspotInteraction: 'taoQtiItem/qtiItem/core/interactions/HotspotInteraction',\n hottextInteraction: 'taoQtiItem/qtiItem/core/interactions/HottextInteraction',\n inlineChoiceInteraction: 'taoQtiItem/qtiItem/core/interactions/InlineChoiceInteraction',\n matchInteraction: 'taoQtiItem/qtiItem/core/interactions/MatchInteraction',\n mediaInteraction: 'taoQtiItem/qtiItem/core/interactions/MediaInteraction',\n orderInteraction: 'taoQtiItem/qtiItem/core/interactions/OrderInteraction',\n prompt: 'taoQtiItem/qtiItem/core/interactions/Prompt',\n selectPointInteraction: 'taoQtiItem/qtiItem/core/interactions/SelectPointInteraction',\n sliderInteraction: 'taoQtiItem/qtiItem/core/interactions/SliderInteraction',\n textEntryInteraction: 'taoQtiItem/qtiItem/core/interactions/TextEntryInteraction',\n uploadInteraction: 'taoQtiItem/qtiItem/core/interactions/UploadInteraction',\n feedbackBlock: 'taoQtiItem/qtiItem/core/feedbacks/FeedbackBlock',\n feedbackInline: 'taoQtiItem/qtiItem/core/feedbacks/FeedbackInline',\n modalFeedback: 'taoQtiItem/qtiItem/core/feedbacks/ModalFeedback',\n customInteraction: 'taoQtiItem/qtiItem/core/interactions/CustomInteraction',\n infoControl: 'taoQtiItem/qtiItem/core/PortableInfoControl',\n include: 'taoQtiItem/qtiItem/core/Include',\n table: 'taoQtiItem/qtiItem/core/Table',\n printedVariable: 'taoQtiItem/qtiItem/core/PrintedVariable',\n _tooltip: 'taoQtiItem/qtiItem/core/Tooltip'\n };\n\n return qtiClasses;\n\n});\n\n","define('taoQtiItem/qtiItem/helper/util',['lodash'], function (_) { 'use strict';\n\n _ = _ && Object.prototype.hasOwnProperty.call(_, 'default') ? _['default'] : _;\n\n /*\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2015 (original work) Open Assessment Technologies SA\n *\n */\n\n var util = {\n buildSerial: function buildSerial(prefix) {\n var id = prefix || '';\n var chars = 'abcdefghijklmnopqrstuvwxyz0123456789';\n for (var i = 0; i < 22; i++) {\n id += chars.charAt(Math.floor(Math.random() * chars.length));\n }\n return id;\n },\n\n /**\n * Generates an id for a Qti element (the generation is different from identifier)\n * @param {Object} item - the element related item\n * @param {String} prefix - identifier prefix\n * @returns {String} the identifier\n * @throws {TypeError} if there is no item\n */\n buildId: function buildId(item, prefix) {\n var id;\n var usedIds;\n var i = 1;\n var suffix = '';\n var exists = false;\n\n if (!item) {\n throw new TypeError('A item is required to generate a unique identifier');\n }\n\n usedIds = item.getUsedIds();\n\n do {\n exists = false;\n id = prefix + suffix;\n if (_.contains(usedIds, id)) {\n exists = true;\n suffix = '_' + i;\n i++;\n }\n } while (exists);\n\n return id;\n },\n\n /**\n * Generates an identifier for a Qti element\n * @param {Object} item - the element related item\n * @param {String} prefix - identifier prefix\n * @param {Boolean} [useSuffix = true] - add a \"_ + index\" to the identifier\n * @returns {String} the identifier\n * @throws {TypeError} if there is no item\n */\n buildIdentifier: function buildIdentifier(item, prefix, useSuffix) {\n var id;\n var usedIds;\n var suffix = '';\n var i = 1;\n var exists = false;\n\n if (!item) {\n throw new TypeError('A item is required to generate a unique identifier');\n }\n\n if (!prefix) {\n throw new TypeError('Prefix is required to build an identifier');\n }\n\n usedIds = item.getUsedIdentifiers();\n useSuffix = _.isUndefined(useSuffix) ? true : useSuffix;\n\n if (prefix) {\n prefix = prefix\n .replace(/_[0-9]+$/gi, '_') //detect incremental id of type choice_12, response_3, etc.\n .replace(/[^a-zA-Z0-9_]/gi, '_')\n .replace(/(_)+/gi, '_');\n if (useSuffix) {\n suffix = '_' + i;\n }\n }\n\n do {\n exists = false;\n id = prefix + suffix;\n if (usedIds[id]) {\n exists = true;\n suffix = '_' + i;\n i++;\n }\n } while (exists);\n\n return id;\n },\n\n findInCollection: function findInCollection(element, collectionNames, searchedSerial) {\n var found = null;\n\n if (_.isString(collectionNames)) {\n collectionNames = [collectionNames];\n }\n\n if (_.isArray(collectionNames)) {\n _.each(collectionNames, function(collectionName) {\n //get collection to search in (resolving case like interaction.choices.0\n var collection = element;\n _.each(collectionName.split('.'), function(nameToken) {\n collection = collection[nameToken];\n });\n var elt = collection[searchedSerial];\n\n if (elt) {\n found = { parent: element, element: elt };\n return false; //break the each loop\n }\n\n //search inside each elements:\n _.each(collection, function(elt) {\n if (_.isFunction(elt.find)) {\n found = elt.find(searchedSerial);\n if (found) {\n return false; //break the each loop\n }\n }\n });\n\n if (found) {\n return false; //break the each loop\n }\n });\n } else {\n throw new Error('invalid argument : collectionNames must be an array or a string');\n }\n\n return found;\n },\n addMarkupNamespace: function addMarkupNamespace(markup, ns) {\n if (ns) {\n markup = markup.replace(/<(\\/)?([a-z:]+)(\\s?)([^><]*)>/g, function($0, $1, $2, $3, $4) {\n if ($2.indexOf(':') > 0) {\n return $0;\n }\n $1 = $1 || '';\n $3 = $3 || '';\n return '<' + $1 + ns + ':' + $2 + $3 + $4 + '>';\n });\n return markup;\n }\n return markup;\n },\n removeMarkupNamespaces: function removeMarkupNamespace(markup) {\n return markup.replace(/<(\\/)?(\\w*):([^>]*)>/g, '<$1$3>');\n },\n getMarkupUsedNamespaces: function getMarkupUsedNamespaces(markup) {\n var namespaces = [];\n markup.replace(/<(\\/)?(\\w*):([^>]*)>/g, function(original, slash, ns, node) {\n namespaces.push(ns);\n return '<' + slash + node + '>';\n });\n return _.uniq(namespaces);\n }\n };\n\n return util;\n\n});\n\n","define('taoQtiItem/qtiItem/helper/rendererConfig',['lodash', 'jquery'], function (_, $) { 'use strict';\n\n _ = _ && Object.prototype.hasOwnProperty.call(_, 'default') ? _['default'] : _;\n $ = $ && Object.prototype.hasOwnProperty.call($, 'default') ? $['default'] : $;\n\n var rendererConfigHelper = {};\n\n rendererConfigHelper.getOptionsFromArguments = function(args) {\n var options = {\n data: {},\n placeholder: null,\n subclass: '',\n renderer: null\n };\n\n _.each(args, function(arg) {\n if (arg) {\n if (arg.isRenderer) {\n options.renderer = arg;\n } else if (arg instanceof $ && arg.length) {\n options.placeholder = arg;\n } else if (_.isString(arg)) {\n options.subclass = arg;\n } else if (_.isPlainObject(arg)) {\n options.data = arg;\n } else {\n console.log('invalid arg', arg, args);\n }\n }\n });\n\n return options;\n };\n\n return rendererConfigHelper;\n\n});\n\n","define('taoQtiItem/qtiItem/core/Element',['jquery', 'lodash', 'class', 'core/logger', 'taoQtiItem/qtiItem/helper/util', 'taoQtiItem/qtiItem/helper/rendererConfig'], function ($, _, _class, loggerFactory, util, rendererConfig) { 'use strict';\n\n $ = $ && Object.prototype.hasOwnProperty.call($, 'default') ? $['default'] : $;\n _ = _ && Object.prototype.hasOwnProperty.call(_, 'default') ? _['default'] : _;\n loggerFactory = loggerFactory && Object.prototype.hasOwnProperty.call(loggerFactory, 'default') ? loggerFactory['default'] : loggerFactory;\n util = util && Object.prototype.hasOwnProperty.call(util, 'default') ? util['default'] : util;\n rendererConfig = rendererConfig && Object.prototype.hasOwnProperty.call(rendererConfig, 'default') ? rendererConfig['default'] : rendererConfig;\n\n /*\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2015 (original work) Open Assessment Technologies SA\n *\n */\n\n var _instances = {};\n\n /**\n * Create a logger\n */\n var logger = loggerFactory('taoQtiItem/qtiItem/core/Element');\n\n var Element = Class.extend({\n qtiClass: '',\n serial: '',\n rootElement: null,\n init: function(serial, attributes) {\n //init own attributes\n this.attributes = {};\n\n //system properties, for item creator internal use only\n this.metaData = {};\n\n //init call in the format init(attributes)\n if (typeof serial === 'object') {\n attributes = serial;\n serial = '';\n }\n\n if (!serial) {\n serial = util.buildSerial(this.qtiClass + '_');\n }\n\n if (serial && (typeof serial !== 'string' || !serial.match(/^[a-z_0-9]*$/i))) {\n throw 'invalid QTI serial : (' + typeof serial + ') ' + serial;\n }\n\n if (!_instances[serial]) {\n _instances[serial] = this;\n this.serial = serial;\n this.setAttributes(attributes || {});\n } else {\n throw 'a QTI Element with the same serial already exists ' + serial;\n }\n\n if (typeof this.initContainer === 'function') {\n this.initContainer(arguments[2] || '');\n }\n if (typeof this.initObject === 'function') {\n this.initObject();\n }\n },\n is: function(qtiClass) {\n return qtiClass === this.qtiClass;\n },\n placeholder: function() {\n return '{{' + this.serial + '}}';\n },\n getSerial: function() {\n return this.serial;\n },\n getUsedIdentifiers: function() {\n var usedIds = {};\n var elts = this.getComposingElements();\n for (var i in elts) {\n var elt = elts[i];\n var id = elt.attr('identifier');\n if (id) {\n //warning: simplistic implementation, allow only one unique identifier in the item no matter the element class/type\n usedIds[id] = elt;\n }\n }\n return usedIds;\n },\n\n /**\n * Get the ids in use. (id is different from identifier)\n * @returns {Array} of the ids in use\n */\n getUsedIds: function getUsedIds() {\n var usedIds = [];\n _.forEach(this.getComposingElements(), function(elt) {\n var id = elt.attr('id');\n if (id && !_.contains(usedIds, id)) {\n usedIds.push(id);\n }\n });\n return usedIds;\n },\n\n attr: function(name, value) {\n if (name) {\n if (value !== undefined) {\n this.attributes[name] = value;\n } else {\n if (typeof name === 'object') {\n for (var prop in name) {\n this.attr(prop, name[prop]);\n }\n } else if (typeof name === 'string') {\n if (this.attributes[name] === undefined) {\n return undefined;\n } else {\n return this.attributes[name];\n }\n }\n }\n }\n return this;\n },\n data: function(name, value) {\n if (name) {\n if (value !== undefined) {\n this.metaData[name] = value;\n $(document).trigger('metaChange.qti-widget', { element: this, key: name, value: value });\n } else {\n if (typeof name === 'object') {\n for (var prop in name) {\n this.data(prop, name[prop]);\n }\n } else if (typeof name === 'string') {\n if (this.metaData[name] === undefined) {\n return undefined;\n } else {\n return this.metaData[name];\n }\n }\n }\n }\n return this;\n },\n removeData: function(name) {\n delete this.metaData[name];\n return this;\n },\n removeAttr: function(name) {\n return this.removeAttributes(name);\n },\n setAttributes: function(attributes) {\n if (!_.isPlainObject(attributes)) {\n logger.warn('attributes should be a plain object');\n }\n this.attributes = attributes;\n return this;\n },\n getAttributes: function() {\n return _.clone(this.attributes);\n },\n removeAttributes: function(attrNames) {\n if (typeof attrNames === 'string') {\n attrNames = [attrNames];\n }\n for (var i in attrNames) {\n delete this.attributes[attrNames[i]];\n }\n return this;\n },\n getComposingElements: function() {\n var elts = {};\n function append(element) {\n elts[element.getSerial()] = element; //pass individual object by ref, instead of the whole list(object)\n elts = _.extend(elts, element.getComposingElements());\n }\n if (typeof this.initContainer === 'function') {\n append(this.getBody());\n }\n if (typeof this.initObject === 'function') {\n append(this.getObject());\n }\n _.each(this.metaData, function(v) {\n if (Element.isA(v, '_container')) {\n append(v);\n } else if (_.isArray(v)) {\n _.each(v, function(v) {\n if (Element.isA(v, '_container')) {\n append(v);\n }\n });\n }\n });\n return elts;\n },\n getUsedClasses: function() {\n var ret = [this.qtiClass],\n composingElts = this.getComposingElements();\n\n _.each(composingElts, function(elt) {\n ret.push(elt.qtiClass);\n });\n\n return _.uniq(ret);\n },\n find: function(serial) {\n var found = null;\n var object, body;\n\n if (typeof this.initObject === 'function') {\n object = this.getObject();\n if (object.serial === serial) {\n found = { parent: this, element: object, location: 'object' };\n }\n }\n\n if (!found && typeof this.initContainer === 'function') {\n body = this.getBody();\n if (body.serial === serial) {\n found = { parent: this, element: body, location: 'body' };\n } else {\n found = this.getBody().find(serial, this);\n }\n }\n\n return found;\n },\n parent: function() {\n var item = this.getRootElement();\n if (item) {\n var found = item.find(this.getSerial());\n if (found) {\n return found.parent;\n }\n }\n return null;\n },\n /**\n * @deprecated - use setRootElement() instead\n */\n setRelatedItem: function(item) {\n logger.warn('Deprecated use of setRelatedItem()');\n this.setRootElement(item);\n },\n setRootElement: function(item) {\n var composingElts, i;\n\n if (Element.isA(item, 'assessmentItem')) {\n this.rootElement = item;\n composingElts = this.getComposingElements();\n for (i in composingElts) {\n composingElts[i].setRootElement(item);\n }\n }\n },\n /**\n * @deprecated - use getRootElement() instead\n */\n getRelatedItem: function() {\n logger.warn('Deprecated use of getRelatedItem()');\n return this.getRootElement();\n },\n getRootElement: function() {\n var ret = null;\n if (Element.isA(this.rootElement, 'assessmentItem')) {\n ret = this.rootElement;\n }\n return ret;\n },\n setRenderer: function(renderer) {\n if (renderer && renderer.isRenderer) {\n this.renderer = renderer;\n var elts = this.getComposingElements();\n for (var serial in elts) {\n elts[serial].setRenderer(renderer);\n }\n } else {\n throw 'invalid qti rendering engine';\n }\n },\n getRenderer: function() {\n return this.renderer;\n },\n /**\n * Render the element. Arguments are all optional and can be given in any order.\n * Argument parsing is based on argument type and is done by taoQtiItem/qtiItem/core/helpers/rendererConfig\n * @param {Renderer} renderer - specify which renderer to use\n * @param {jQuery} placeholder - DOM element that will be replaced by the rendered element\n * @param {Object} data - template data for the rendering\n * @param {String} subclass - subclass enables different behaviour of the same qti class in different contexts (eg. we could have different rendering for simpleChoice according to where it is being used: simpleChoice.orderInteraction, simpleChoice.choiceInteraction...)\n * @returns {String} - the rendered element as an HTML string\n */\n render: function render() {\n var args = rendererConfig.getOptionsFromArguments(arguments);\n var _renderer = args.renderer || this.getRenderer();\n var rendering;\n\n var tplData = {},\n defaultData = {\n tag: this.qtiClass,\n serial: this.serial,\n attributes: this.getAttributes()\n };\n\n if (!_renderer) {\n throw new Error('render: no renderer found for the element ' + this.qtiClass + ':' + this.serial);\n }\n\n if (typeof this.initContainer === 'function') {\n //allow body to have a different renderer if it has its own renderer set\n defaultData.body = this.getBody().render(args.renderer);\n }\n if (typeof this.initObject === 'function') {\n defaultData.object = {\n attributes: this.object.getAttributes()\n };\n defaultData.object.attributes.data = _renderer.resolveUrl(this.object.attr('data'));\n }\n\n tplData = _.merge(defaultData, args.data || {});\n tplData = _renderer.getData(this, tplData, args.subclass);\n rendering = _renderer.renderTpl(this, tplData, args.subclass);\n if (args.placeholder) {\n args.placeholder.replaceWith(rendering);\n }\n\n return rendering;\n },\n postRender: function(data, altClassName, renderer) {\n var postRenderers = [];\n var _renderer = renderer || this.getRenderer();\n\n if (typeof this.initContainer === 'function') {\n //allow body to have a different renderer if it has its own renderer set\n postRenderers = this.getBody().postRender(data, '', renderer);\n }\n\n if (_renderer) {\n postRenderers.push(_renderer.postRender(this, data, altClassName));\n } else {\n throw 'postRender: no renderer found for the element ' + this.qtiClass + ':' + this.serial;\n }\n\n return _.compact(postRenderers);\n },\n getContainer: function($scope, subclass) {\n var renderer = this.getRenderer();\n if (renderer) {\n return renderer.getContainer(this, $scope, subclass);\n } else {\n throw 'getContainer: no renderer found for the element ' + this.qtiClass + ':' + this.serial;\n }\n },\n toArray: function() {\n var arr = {\n serial: this.serial,\n type: this.qtiClass,\n attributes: this.getAttributes()\n };\n\n if (typeof this.initContainer === 'function') {\n arr.body = this.getBody().toArray();\n }\n if (typeof this.initObject === 'function') {\n arr.object = this.object.toArray();\n }\n\n return arr;\n },\n isEmpty: function() {\n //tells whether the element should be considered empty or not, from the rendering point of view\n return false;\n },\n addClass: function(className) {\n var clazz = this.attr('class') || '';\n if (!_containClass(clazz, className)) {\n this.attr('class', clazz + (clazz.length ? ' ' : '') + className);\n }\n },\n hasClass: function(className) {\n return _containClass(this.attr('class'), className);\n },\n removeClass: function(className) {\n var clazz = this.attr('class') || '';\n if (clazz) {\n var regex = new RegExp('(?:^|\\\\s)' + className + '(?:\\\\s|$)');\n clazz = clazz.replace(regex, ' ').trim();\n\n if (clazz) {\n this.attr('class', clazz);\n } else {\n this.removeAttr('class');\n }\n }\n },\n /**\n * Add or remove class. Setting the optional state will force addition/removal.\n * State is here to keep the jQuery syntax\n *\n * @param {String} className\n * @param {Boolean} [state]\n */\n toggleClass: function(className, state) {\n if (typeof state === 'boolean') {\n return state ? this.addClass(className) : this.removeClass(className);\n }\n\n if (this.hasClass(className)) {\n return this.removeClass(className);\n }\n return this.addClass(className);\n },\n isset: function() {\n return Element.issetElement(this.serial);\n },\n unset: function() {\n return Element.unsetElement(this.serial);\n }\n });\n\n var _containClass = function(allClassStr, className) {\n var regex = new RegExp('(?:^|\\\\s)' + className + '(?:\\\\s|$)', '');\n return allClassStr && regex.test(allClassStr);\n };\n\n //helpers\n Element.isA = function(qtiElement, qtiClass) {\n return qtiElement instanceof Element && qtiElement.is(qtiClass);\n };\n\n Element.getElementBySerial = function(serial) {\n return _instances[serial];\n };\n\n Element.issetElement = function(serial) {\n return !!_instances[serial];\n };\n\n /**\n * Unset a registered element from it's serial\n * @param {String} serial - the element serial\n * @returns {Boolean} true if unset\n */\n Element.unsetElement = function(serial) {\n var element = Element.getElementBySerial(serial);\n\n if (element) {\n var composingElements = element.getComposingElements();\n _.each(composingElements, function(elt) {\n delete _instances[elt.serial];\n });\n delete _instances[element.serial];\n\n return true;\n }\n return false;\n };\n\n return Element;\n\n});\n\n","define('taoQtiItem/qtiItem/helper/xmlNsHandler',[],function () { 'use strict';\n\n /*\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2017-2022 (original work) Open Assessment Technologies SA\n */\n\n /**\n * XML namespace handling\n */\n\n /**\n * Elements that need to be prefixed\n *\n * @see http://www.imsglobal.org/xsd/qti/qtiv2p2/imsqti_v2p2.xsd\n * @type {string}\n */\n const prefixed = 'article|aside|bdi|figure|footer|header|nav|rb|rp|rt|rtc|ruby|section';\n\n /**\n * Find a possibly existing prefix\n *\n * @param namespaces\n * @param html5Ns\n * @returns {*}\n */\n function getPrefix(namespaces, html5Ns) {\n let key;\n for (key in namespaces) {\n if (namespaces[key] === html5Ns) {\n return key;\n }\n }\n return 'qh5';\n }\n\n var xmlNsHandler = {\n /**\n * Remove prefix to make sure elements are properly displayed\n *\n * @param body\n */\n stripNs: function stripNs(body) {\n const pattern = '([\\\\w]+)\\\\:(' + prefixed + ')';\n const openRegEx = new RegExp('(<' + pattern + ')', 'gi');\n const closeRegEx = new RegExp('(<\\\\/' + pattern + '>)', 'gi');\n return body.replace(openRegEx, '<$3').replace(closeRegEx, '');\n },\n\n /**\n * Add a prefix to those elements that require one\n *\n * @param xml\n * @param namespaces\n * @returns {*}\n */\n restoreNs: function restoreNs(xml, namespaces, ignoreMarkup = false) {\n let xmlCopy = xml;\n if (ignoreMarkup) {\n // cut from xmlCopy ...\n // because markup should be html without namespace qh5\n xmlCopy = xml.replace(/((?=)+)/gim, '');\n }\n const xmlRe = new RegExp('(<(' + prefixed + ')[^>]*>|<\\\\/(' + prefixed + ')>)', 'gi');\n const tagRe = new RegExp('((<)(' + prefixed + ')([^>]*)(>)|(<\\\\/)(' + prefixed + ')(>))', 'i');\n const xmlMatch = xmlCopy.match(xmlRe);\n const imsXsd = 'http://www.imsglobal.org/xsd';\n const html5Ns = imsXsd + '/imsqtiv2p2_html5_v1p0';\n const prefix = getPrefix(namespaces, html5Ns);\n const prefixAtt = 'xmlns:' + prefix + '=\"' + html5Ns + '\"';\n let i = xmlMatch ? xmlMatch.length : 0;\n\n if (!xmlMatch) {\n return xml;\n }\n\n while (i--) {\n const tagMatch = xmlMatch[i].match(tagRe);\n xml = xml.replace(\n xmlMatch[i],\n tagMatch[5]\n ? '<' + prefix + ':' + tagMatch[3] + tagMatch[4] + '>'\n : ''\n );\n }\n\n // we found matches but no namespace has been set\n if (xmlMatch.length && xml.indexOf(prefixAtt) === -1) {\n xml = xml.replace(' ({\n qtiClass: 'responseCondition',\n responseIf: {\n qtiClass: 'responseIf',\n expression: {\n qtiClass: 'match',\n expressions: [\n {\n qtiClass: 'variable',\n attributes: {\n identifier: responseIdentifier,\n },\n },\n {\n qtiClass: 'correct',\n attributes: {\n identifier: responseIdentifier,\n },\n },\n ],\n },\n responseRules: [\n {\n qtiClass: 'setOutcomeValue',\n attributes: {\n identifier: outcomeIdentifier,\n },\n expression: {\n qtiClass: 'sum',\n expressions: [\n {\n qtiClass: 'variable',\n attributes: {\n identifier: outcomeIdentifier,\n },\n },\n {\n qtiClass: 'baseValue',\n attributes: {\n baseType: 'integer'\n },\n value: '1',\n },\n ],\n },\n },\n ],\n },\n }),\n MAP_RESPONSE: (responseIdentifier, outcomeIdentifier) => ({\n qtiClass: 'responseCondition',\n responseIf: {\n qtiClass: 'responseIf',\n expression: {\n qtiClass: 'not',\n expressions: [\n {\n qtiClass: 'isNull',\n expressions: [{\n qtiClass: 'variable',\n attributes: {\n identifier: responseIdentifier,\n },\n }],\n },\n ],\n },\n responseRules: [\n {\n qtiClass: 'setOutcomeValue',\n attributes: {\n identifier: outcomeIdentifier,\n },\n expression: {\n qtiClass: 'sum',\n expressions: [\n {\n qtiClass: 'variable',\n attributes: {\n identifier: outcomeIdentifier,\n }\n },\n {\n qtiClass: 'mapResponse',\n attributes: {\n identifier: responseIdentifier,\n },\n },\n ],\n },\n },\n ],\n },\n }),\n MAP_RESPONSE_POINT: (responseIdentifier, outcomeIdentifier) => ({\n qtiClass: 'responseCondition',\n responseIf: {\n qtiClass: 'responseIf',\n expression: {\n qtiClass: 'not',\n expressions: [\n {\n qtiClass: 'isNull',\n expressions: [{\n qtiClass: 'variable',\n attributes: {\n identifier: responseIdentifier,\n },\n }],\n },\n ],\n },\n responseRules: [\n {\n qtiClass: 'setOutcomeValue',\n attributes: {\n identifier: outcomeIdentifier,\n },\n expression: {\n qtiClass: 'sum',\n expressions: [\n {\n qtiClass: 'variable',\n attributes: {\n identifier: outcomeIdentifier,\n }\n },\n {\n qtiClass: 'mapResponsePoint',\n attributes: {\n identifier: responseIdentifier,\n },\n },\n ],\n },\n },\n ],\n },\n }),\n };\n\n return responseRules;\n\n});\n\n","define('taoQtiItem/qtiItem/helper/response',['lodash', 'taoQtiItem/qtiItem/helper/responseRules'], function (_, responseRulesHelper) { 'use strict';\n\n _ = _ && Object.prototype.hasOwnProperty.call(_, 'default') ? _['default'] : _;\n responseRulesHelper = responseRulesHelper && Object.prototype.hasOwnProperty.call(responseRulesHelper, 'default') ? responseRulesHelper['default'] : responseRulesHelper;\n\n /*\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2014-2020 (original work) Open Assessment Technologies SA (under the project TAO-PRODUCT);\n *\n */\n\n const _templateNames = {\n MATCH_CORRECT: 'http://www.imsglobal.org/question/qti_v2p1/rptemplates/match_correct',\n MAP_RESPONSE: 'http://www.imsglobal.org/question/qti_v2p1/rptemplates/map_response',\n MAP_RESPONSE_POINT: 'http://www.imsglobal.org/question/qti_v2p1/rptemplates/map_response_point',\n NONE: 'no_response_processing'\n };\n\n\n var response = {\n isUsingTemplate(response, tpl) {\n if (_.isString(tpl)) {\n if (tpl === response.template || _templateNames[tpl] === response.template) {\n return true;\n }\n }\n\n return false;\n },\n isValidTemplateName(tplName) {\n return !!this.getTemplateUriFromName(tplName);\n },\n getTemplateUriFromName(tplName) {\n return _templateNames[tplName] || '';\n },\n getTemplateNameFromUri(tplUri) {\n let tplName = '';\n\n _.forIn(_templateNames, (uri, name) => {\n if (uri === tplUri) {\n tplName = name;\n return false;\n }\n });\n\n return tplName;\n },\n getTemplateNameFromResponseRules(responseIdentifier, responseRules) {\n if (!responseRules) {\n return 'NONE';\n }\n\n const {\n responseIf: {\n responseRules: [outcomeRules = {}] = [],\n } = {}\n } = responseRules;\n const {\n attributes: {\n identifier: outcomeIdentifier,\n } = {},\n } = outcomeRules;\n\n if (!outcomeIdentifier) {\n return '';\n }\n\n return Object.keys(responseRulesHelper).find(\n (key) => _.isEqual(responseRules, responseRulesHelper[key](responseIdentifier, outcomeIdentifier))\n );\n }\n };\n\n return response;\n\n});\n\n","define('taoQtiItem/qtiItem/helper/itemScore',[],function () { 'use strict';\n\n /*\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2020 (original work) Open Assessment Technologies SA (under the project TAO-PRODUCT);\n *\n */\n\n /**\n * Returns iteraction score response rule object\n *\n * @param {String} responseIdentifiers interactions reponse indentifiers\n * @returns {Obeject}\n */\n var itemScore = (responseIdentifiers) => {\n const outcomeExpressions = responseIdentifiers.map((outcomeIdentifier) => ({\n qtiClass: 'variable',\n attributes: {\n identifier: `SCORE_${outcomeIdentifier}`,\n },\n }));\n\n return {\n qtiClass: 'setOutcomeValue',\n attributes: {\n identifier: 'SCORE',\n },\n expression: {\n qtiClass: 'sum',\n expressions: outcomeExpressions,\n },\n };\n };\n\n return itemScore;\n\n});\n\n","define('taoQtiItem/qtiItem/core/Loader',['lodash', 'class', 'taoQtiItem/qtiItem/core/qtiClasses', 'taoQtiItem/qtiItem/core/Element', 'taoQtiItem/qtiItem/helper/xmlNsHandler', 'core/moduleLoader', 'taoQtiItem/qtiItem/helper/response', 'taoQtiItem/qtiItem/helper/itemScore'], function (_, _class, qtiClasses, Element, xmlNsHandler, moduleLoader, responseHelper, itemScoreHelper) { 'use strict';\n\n _ = _ && Object.prototype.hasOwnProperty.call(_, 'default') ? _['default'] : _;\n qtiClasses = qtiClasses && Object.prototype.hasOwnProperty.call(qtiClasses, 'default') ? qtiClasses['default'] : qtiClasses;\n Element = Element && Object.prototype.hasOwnProperty.call(Element, 'default') ? Element['default'] : Element;\n xmlNsHandler = xmlNsHandler && Object.prototype.hasOwnProperty.call(xmlNsHandler, 'default') ? xmlNsHandler['default'] : xmlNsHandler;\n moduleLoader = moduleLoader && Object.prototype.hasOwnProperty.call(moduleLoader, 'default') ? moduleLoader['default'] : moduleLoader;\n responseHelper = responseHelper && Object.prototype.hasOwnProperty.call(responseHelper, 'default') ? responseHelper['default'] : responseHelper;\n itemScoreHelper = itemScoreHelper && Object.prototype.hasOwnProperty.call(itemScoreHelper, 'default') ? itemScoreHelper['default'] : itemScoreHelper;\n\n /*\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2015-2020 (original work) Open Assessment Technologies SA ;\n *\n */\n\n /**\n * If a property is given as a serialized JSON object, parse it directly to a JS object\n */\n const loadPortableCustomElementProperties = (portableElement, rawProperties) => {\n var properties = {};\n\n _.forOwn(rawProperties, (value, key) => {\n try {\n properties[key] = JSON.parse(value);\n } catch (e) {\n properties[key] = value;\n }\n });\n portableElement.properties = properties;\n };\n\n const loadPortableCustomElementData = (portableElement, data) => {\n portableElement.typeIdentifier = data.typeIdentifier;\n portableElement.markup = data.markup;\n portableElement.entryPoint = data.entryPoint;\n portableElement.libraries = data.libraries;\n portableElement.setNamespace('', data.xmlns);\n\n loadPortableCustomElementProperties(portableElement, data.properties);\n };\n\n var Loader = Class.extend({\n init(item, classesLocation) {\n this.qti = {}; //loaded qti classes are store here\n this.classesLocation = {};\n this.item = item || null; //starts either from scratch or with an existing item object\n\n this.setClassesLocation(classesLocation || qtiClasses); //load default location for qti classes model\n },\n setClassesLocation(qtiClassesList) {\n _.extend(this.classesLocation, qtiClassesList);\n\n return this;\n },\n getRequiredClasses(data) {\n let ret = [];\n\n for (let i in data) {\n if (i === 'qtiClass' && data[i] !== '_container' && i !== 'rootElement') {\n //although a _container is a concrete class in TAO, it is not defined in QTI standard\n ret.push(data[i]);\n } else if (typeof data[i] === 'object' && i !== 'responseRules') {\n //responseRules should'nt be part of the parsing\n ret = _.union(ret, this.getRequiredClasses(data[i]));\n }\n }\n\n return ret;\n },\n loadRequiredClasses(data, callback, reload) {\n let requiredClass;\n const requiredClasses = this.getRequiredClasses(data, reload);\n const required = [];\n\n for (let i in requiredClasses) {\n requiredClass = requiredClasses[i];\n if (this.classesLocation[requiredClass]) {\n required.push({\n module: this.classesLocation[requiredClass],\n category: 'qti'\n });\n } else {\n throw new Error(`missing qti class location declaration : ${requiredClass}`);\n }\n }\n\n moduleLoader([], () => true).addList(required).load().then(loadeded => {\n loadeded.forEach(QtiClass => {\n this.qti[QtiClass.prototype.qtiClass] = QtiClass;\n });\n callback.call(this, this.qti);\n });\n },\n getLoadedClasses() {\n return _.keys(this.qti);\n },\n loadItemData(data, callback) {\n this.loadRequiredClasses(data, Qti => {\n if (typeof data === 'object' && data.qtiClass === 'assessmentItem') {\n //unload an item from it's serial (in case of a reload)\n if (data.serial) {\n Element.unsetElement(data.serial);\n }\n\n this.item = new Qti.assessmentItem(data.serial, data.attributes || {});\n this.loadContainer(this.item.getBody(), data.body);\n\n for (let i in data.outcomes) {\n const outcome = this.buildOutcome(data.outcomes[i]);\n\n if (outcome) {\n this.item.addOutcomeDeclaration(outcome);\n }\n }\n\n for (let i in data.feedbacks) {\n const feedback = this.buildElement(data.feedbacks[i]);\n\n if (feedback) {\n this.item.addModalFeedback(feedback);\n }\n }\n\n for (let i in data.stylesheets) {\n const stylesheet = this.buildElement(data.stylesheets[i]);\n\n if (stylesheet) {\n this.item.addStylesheet(stylesheet);\n }\n }\n\n //important : build responses after all modal feedbacks and outcomes has been loaded, because the simple feedback rules need to reference them\n let responseRules = data.responseProcessing && data.responseProcessing.responseRules\n ? [...data.responseProcessing.responseRules]\n : [];\n for (let i in data.responses) {\n const responseIdentifier = data.responses[i].identifier;\n const responseRuleItemIndex = responseRules.findIndex(({ responseIf: {\n expression: {\n expressions: [expression = {}] = [],\n } = {}\n } = {} }) => expression.attributes\n && expression.attributes.identifier === responseIdentifier\n || (\n expression.expressions\n && expression.expressions[0]\n && expression.expressions[0].attributes\n && expression.expressions[0].attributes.identifier === responseIdentifier\n )\n );\n const [responseRule] = responseRuleItemIndex !== -1\n ? responseRules.splice(responseRuleItemIndex, 1)\n : [];\n\n const response = this.buildResponse(\n data.responses[i],\n responseRule\n );\n\n if (response) {\n this.item.addResponseDeclaration(response);\n\n const feedbackRules = data.responses[i].feedbackRules;\n\n if (feedbackRules) {\n _.forIn(feedbackRules, (fbData, serial) => {\n const {\n attributes: {\n identifier: feedbackOutcomeIdentifier,\n } = {}\n } = data.outcomes[fbData.feedbackOutcome] || {};\n response.feedbackRules[serial] = this.buildSimpleFeedbackRule(fbData, response);\n\n // remove feedback response rule from response rules array\n const feedbackResponseRuleIndex = responseRules.findIndex(({\n responseIf: {\n responseRules: [setOutcomeResponseRule = {}] = [],\n } = {}\n }) => {\n const { attributes = {}, qtiClass } = setOutcomeResponseRule;\n const outcomeIdentifier = attributes.identifier;\n\n return feedbackOutcomeIdentifier === outcomeIdentifier\n && qtiClass === 'setOutcomeValue';\n });\n\n if (feedbackResponseRuleIndex !== -1) {\n responseRules.splice(feedbackResponseRuleIndex, 1);\n }\n });\n }\n }\n }\n\n const responseIdentifiers = Object.keys(this.item.responses || {})\n .map((responseKey) => this.item.responses[responseKey].attributes.identifier);\n\n if (data.responseProcessing) {\n const customResponseProcessing =\n (\n responseRules.length > 0\n && !(\n responseRules.length === 1\n && _.isEqual(\n responseRules[0],\n itemScoreHelper(\n responseIdentifiers\n )\n )\n )\n )\n || (\n this.item.responses\n && Object.keys(this.item.responses)\n .some((responseKey) => !this.item.responses[responseKey].template)\n );\n\n this.item.setResponseProcessing(this.buildResponseProcessing(data.responseProcessing, customResponseProcessing));\n }\n this.item.setNamespaces(data.namespaces);\n this.item.setSchemaLocations(data.schemaLocations);\n this.item.setApipAccessibility(data.apipAccessibility);\n }\n\n if (typeof callback === 'function') {\n callback.call(this, this.item);\n }\n });\n },\n loadAndBuildElement(data, callback) {\n this.loadRequiredClasses(data, () => {\n const element = this.buildElement(data);\n\n if (typeof callback === 'function') {\n callback.call(this, element);\n }\n });\n },\n loadElement(element, data, callback) {\n this.loadRequiredClasses(data, () => {\n this.loadElementData(element, data);\n\n if (typeof callback === 'function') {\n callback.call(this, element);\n }\n });\n },\n /**\n * Load ALL given elements into existing loaded item\n *\n * @todo to be renamed to loadItemElements\n * @param {object} data\n * @param {function} callback\n * @returns {undefined}\n */\n loadElements(data, callback) {\n if (!this.item) {\n throw new Error('QtiLoader : cannot load elements in empty item');\n }\n\n this.loadRequiredClasses(data, () => {\n const allElements = this.item.getComposingElements();\n\n for (let i in data) {\n const elementData = data[i];\n\n if (elementData && elementData.qtiClass && elementData.serial) {\n //find and update element\n if (allElements[elementData.serial]) {\n this.loadElementData(allElements[elementData.serial], elementData);\n }\n }\n }\n\n if (typeof callback === 'function') {\n callback.call(this, this.item);\n }\n });\n },\n buildResponse(data, responseRule) {\n const response = this.buildElement(data);\n\n response.template = responseHelper.getTemplateUriFromName(\n responseHelper.getTemplateNameFromResponseRules(data.identifier, responseRule)\n )\n || data.howMatch\n || null;\n\n response.defaultValue = data.defaultValue || null;\n response.correctResponse = data.correctResponses || null;\n\n if (_.size(data.mapping)) {\n response.mapEntries = data.mapping;\n } else if (_.size(data.areaMapping)) {\n response.mapEntries = data.areaMapping;\n } else {\n response.mapEntries = {};\n }\n\n response.mappingAttributes = data.mappingAttributes || {};\n\n return response;\n },\n buildSimpleFeedbackRule(data, response) {\n const feedbackRule = this.buildElement(data);\n\n feedbackRule.setCondition(response, data.condition, data.comparedValue || null);\n\n // feedbackRule.comparedOutcome = this.item.responses[data.comparedOutcome] || null;\n feedbackRule.feedbackOutcome = this.item.outcomes[data.feedbackOutcome] || null;\n feedbackRule.feedbackThen = this.item.modalFeedbacks[data.feedbackThen] || null;\n feedbackRule.feedbackElse = this.item.modalFeedbacks[data.feedbackElse] || null;\n\n //associate the compared outcome to the feedbacks if applicable\n const comparedOutcome = feedbackRule.comparedOutcome;\n\n if (feedbackRule.feedbackThen) {\n feedbackRule.feedbackThen.data('relatedResponse', comparedOutcome);\n }\n\n if (feedbackRule.feedbackElse) {\n feedbackRule.feedbackElse.data('relatedResponse', comparedOutcome);\n }\n\n return feedbackRule;\n },\n buildOutcome(data) {\n const outcome = this.buildElement(data);\n outcome.defaultValue = data.defaultValue || null;\n\n return outcome;\n },\n buildResponseProcessing(data, customResponseProcessing) {\n const rp = this.buildElement(data);\n\n if (customResponseProcessing) {\n rp.xml = data.data;\n rp.processingType = 'custom';\n } else {\n rp.processingType = 'templateDriven';\n }\n\n return rp;\n },\n loadContainer(bodyObject, bodyData) {\n if (!Element.isA(bodyObject, '_container')) {\n throw new Error('bodyObject must be a QTI Container');\n }\n\n if (!(bodyData && typeof bodyData.body === 'string' && typeof bodyData.elements === 'object')) {\n throw new Error('wrong bodydata format');\n }\n //merge attributes when loading element data\n const attributes = _.defaults(bodyData.attributes || {}, bodyObject.attributes || {});\n bodyObject.setAttributes(attributes);\n\n for (let serial in bodyData.elements) {\n const eltData = bodyData.elements[serial];\n const element = this.buildElement(eltData);\n\n //check if class is loaded:\n if (element) {\n bodyObject.setElement(element, bodyData.body);\n }\n }\n\n bodyObject.body(xmlNsHandler.stripNs(bodyData.body));\n },\n buildElement(elementData) {\n if (!(elementData && elementData.qtiClass && elementData.serial)) {\n throw new Error('wrong elementData format');\n }\n\n const className = elementData.qtiClass;\n\n if (!this.qti[className]) {\n throw new Error(`the qti element class does not exist: ${className}`);\n }\n\n const elt = new this.qti[className](elementData.serial);\n this.loadElementData(elt, elementData);\n\n return elt;\n },\n loadElementData(element, data) {\n //merge attributes when loading element data\n const attributes = _.defaults(data.attributes || {}, element.attributes || {});\n element.setAttributes(attributes);\n\n let body = data.body;\n if (!body && data.text && data.qtiClass === 'inlineChoice') {\n body = { body: data.text, elements: {} };\n }\n if (element.body && body) {\n if (element.bdy) {\n this.loadContainer(element.getBody(), body);\n }\n }\n\n if (element.object && data.object) {\n if (element.object) {\n this.loadObjectData(element.object, data.object);\n }\n }\n\n if (Element.isA(element, 'interaction')) {\n this.loadInteractionData(element, data);\n } else if (Element.isA(element, 'choice')) {\n this.loadChoiceData(element, data);\n } else if (Element.isA(element, 'math')) {\n this.loadMathData(element, data);\n } else if (Element.isA(element, 'infoControl')) {\n this.loadPicData(element, data);\n } else if (Element.isA(element, '_tooltip')) {\n this.loadTooltipData(element, data);\n }\n\n return element;\n },\n loadInteractionData(interaction, data) {\n if (Element.isA(interaction, 'blockInteraction')) {\n if (data.prompt) {\n this.loadContainer(interaction.prompt.getBody(), data.prompt);\n }\n }\n\n this.buildInteractionChoices(interaction, data);\n\n if (Element.isA(interaction, 'customInteraction')) {\n this.loadPciData(interaction, data);\n }\n },\n buildInteractionChoices(interaction, data) {\n // note: Qti.ContainerInteraction (Qti.GapMatchInteraction and Qti.HottextInteraction) has already been parsed by builtElement(interacionData);\n if (data.choices) {\n if (Element.isA(interaction, 'matchInteraction')) {\n for (let set = 0; set < 2; set++) {\n if (!data.choices[set]) {\n throw new Error(`missing match set #${set}`);\n }\n\n const matchSet = data.choices[set];\n\n for (let serial in matchSet) {\n const choice = this.buildElement(matchSet[serial]);\n\n if (choice) {\n interaction.addChoice(choice, set);\n }\n }\n }\n } else {\n for (let serial in data.choices) {\n const choice = this.buildElement(data.choices[serial]);\n\n if (choice) {\n interaction.addChoice(choice);\n }\n }\n }\n\n if (Element.isA(interaction, 'graphicGapMatchInteraction')) {\n if (data.gapImgs) {\n for (let serial in data.gapImgs) {\n const gapImg = this.buildElement(data.gapImgs[serial]);\n\n if (gapImg) {\n interaction.addGapImg(gapImg);\n }\n }\n }\n }\n }\n },\n loadChoiceData(choice, data) {\n if (Element.isA(choice, 'textVariableChoice')) {\n choice.val(data.text);\n } else if (Element.isA(choice, 'gapImg')) ; else if (Element.isA(choice, 'gapText')) {\n // this ensure compatibility of Qti 2.1 items\n if (!choice.body()) {\n choice.body(data.text);\n }\n } else if (Element.isA(choice, 'containerChoice')) ;\n },\n loadObjectData(object, data) {\n object.setAttributes(data.attributes);\n\n //@todo: manage object like a container\n if (data._alt) {\n if (data._alt.qtiClass === 'object') {\n object._alt = Loader.buildElement(data._alt);\n } else {\n object._alt = data._alt;\n }\n }\n },\n loadMathData(math, data) {\n math.ns = data.ns || {};\n math.setMathML(data.mathML || '');\n _.forIn(data.annotations || {}, (value, encoding) => {\n math.setAnnotation(encoding, value);\n });\n },\n loadTooltipData(tooltip, data) {\n tooltip.content(data.content);\n },\n loadPciData(pci, data) {\n loadPortableCustomElementData(pci, data);\n },\n loadPicData(pic, data) {\n loadPortableCustomElementData(pic, data);\n }\n });\n\n return Loader;\n\n});\n\n","define('taoQtiItem/qtiItem/helper/pci',['lodash'], function (_) { 'use strict';\n\n _ = _ && Object.prototype.hasOwnProperty.call(_, 'default') ? _['default'] : _;\n\n var pci = {\n getRawValues: function(pciVar) {\n if (_.isPlainObject(pciVar)) {\n if (pciVar.base !== undefined) {\n return _.values(pciVar.base);\n } else if (pciVar.list) {\n return _.values(pciVar.list);\n }\n }\n throw 'unsupported type ';\n }\n };\n\n return pci;\n\n});\n\n","define('taoQtiItem/qtiItem/helper/container',['lodash', 'jquery'], function (_, $) { 'use strict';\n\n _ = _ && Object.prototype.hasOwnProperty.call(_, 'default') ? _['default'] : _;\n $ = $ && Object.prototype.hasOwnProperty.call($, 'default') ? $['default'] : $;\n\n /*\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2016 (original work) Open Assessment Technologies SA\n **/\n\n /**\n * Prefix used to the variable storage\n * @type String\n */\n var _prefix = 'x-tao-';\n\n /**\n * Check if the element is of a qti container type\n *\n * @private\n * @param {Object} element\n * @returns {Boolean}\n */\n function _checkContainerType(element) {\n if (_.isFunction(element.initContainer) && _.isFunction(element.body)) {\n return true;\n } else {\n throw 'the element is not of a container type';\n }\n }\n\n /**\n * Get the body element of the container\n *\n * @private\n * @param {Object} element\n * @returns {JQuery}\n */\n function _getBodyDom(element) {\n if (_checkContainerType(element)) {\n return $('
')\n .html(element.body())\n .find('.x-tao-wrapper');\n }\n }\n\n /**\n * Add a class to the body element of the qti container\n *\n * @private\n * @param {Object} element\n * @param {String} newClass\n * @param {String} [oldClass]\n */\n function _setBodyDomClass(element, newClass, oldClass) {\n if (_checkContainerType(element) && (oldClass || newClass)) {\n var $wrapper = $('
').html(element.body());\n //set css class to element\n _setDomClass($wrapper, newClass, oldClass);\n //set to the model\n element.body($wrapper.html());\n }\n }\n\n /**\n * Switch class to the wrapped DOM\n *\n * @param {JQuery} $wrapper\n * @param {String} newClass\n * @param {String} oldClass\n * @returns {undefined}\n */\n function _setDomClass($wrapper, newClass, oldClass) {\n var $bodyDom = $wrapper.find('.x-tao-wrapper');\n if (!$bodyDom.length) {\n //create one\n $wrapper.wrapInner('
');\n $bodyDom = $wrapper.find('.x-tao-wrapper');\n }\n if (oldClass) {\n $bodyDom.removeClass(oldClass);\n }\n if (newClass) {\n $bodyDom.addClass(newClass);\n }\n }\n\n /**\n * Add manually the encoded information to a dom element\n *\n * @param {JQuery} $wrapper - the wrapper of the element that will holds the information\n * @param {String} dataName - the name of the information\n * @param {String} newValue - the new value to be added\n * @param {String} [oldValue] - the old value to be removed\n * @returns {undefined}\n */\n function setEncodedDataToDom($wrapper, dataName, newValue, oldValue) {\n _setDomClass($wrapper, _getEncodedDataString(dataName, newValue), _getEncodedDataString(dataName, oldValue));\n }\n\n /**\n * Get the full variable name for the data store\n *\n * @param {String} dataName\n * @param {String} value\n * @returns {String}\n */\n function _getEncodedDataString(dataName, value) {\n if (dataName && value) {\n return _prefix + dataName + '-' + value;\n }\n return '';\n }\n\n /**\n * Set a data string to the element identified by its dataName\n *\n * @param {Object} element\n * @param {String} dataName\n * @param {String} newValue\n * @returns {undefined}\n */\n function setEncodedData(element, dataName, newValue) {\n var oldValue = getEncodedData(element, dataName);\n return _setBodyDomClass(\n element,\n _getEncodedDataString(dataName, newValue),\n _getEncodedDataString(dataName, oldValue)\n );\n }\n\n /**\n * Remove the stored data from the element by its dataName\n *\n * @param {Object} element\n * @param {String} dataName\n * @returns {unresolved}\n */\n function removeEncodedData(element, dataName) {\n var oldValue = getEncodedData(element, dataName);\n if (dataName && oldValue) {\n _setBodyDomClass(element, '', _getEncodedDataString(dataName, oldValue));\n }\n }\n\n /**\n * Check if the stored data exist\n *\n * @param {Object} element\n * @param {String} dataName\n * @param {String} value\n * @returns {Boolean}\n */\n function hasEncodedData(element, dataName, value) {\n var $body = _getBodyDom(element);\n if ($body && $body.length && dataName && value) {\n return $body.hasClass(_getEncodedDataString(dataName, value));\n }\n return false;\n }\n\n /**\n * Get the encoded data identified by its dataName\n *\n * @param {Object} element\n * @param {String} dataName\n * @returns {String}\n */\n function getEncodedData(element, dataName) {\n var regex, matches;\n var $body = _getBodyDom(element);\n if (dataName && $body && $body.length && $body.attr('class')) {\n regex = new RegExp(_prefix + dataName + '-([a-zA-Z0-9-._]*)');\n matches = $body.attr('class').match(regex);\n if (matches) {\n return matches[1];\n }\n }\n }\n\n /**\n * Provide a set of helper functions to set,retirve and manage string data to a container type qti element.\n */\n var container = {\n setEncodedData: setEncodedData,\n hasEncodedData: hasEncodedData,\n getEncodedData: getEncodedData,\n removeEncodedData: removeEncodedData,\n setEncodedDataToDom: setEncodedDataToDom\n };\n\n return container;\n\n});\n\n","define('taoQtiItem/qtiRunner/modalFeedback/inlineRenderer',['lodash', 'jquery', 'context', 'taoQtiItem/qtiItem/helper/pci', 'taoQtiItem/qtiItem/helper/container', 'handlebars', 'lib/handlebars/helpers', 'iframeNotifier'], function (_, $$1, context, pci, containerHelper, Handlebars, Helpers0, iframeNotifier) { 'use strict';\n\n _ = _ && Object.prototype.hasOwnProperty.call(_, 'default') ? _['default'] : _;\n $$1 = $$1 && Object.prototype.hasOwnProperty.call($$1, 'default') ? $$1['default'] : $$1;\n context = context && Object.prototype.hasOwnProperty.call(context, 'default') ? context['default'] : context;\n pci = pci && Object.prototype.hasOwnProperty.call(pci, 'default') ? pci['default'] : pci;\n containerHelper = containerHelper && Object.prototype.hasOwnProperty.call(containerHelper, 'default') ? containerHelper['default'] : containerHelper;\n Handlebars = Handlebars && Object.prototype.hasOwnProperty.call(Handlebars, 'default') ? Handlebars['default'] : Handlebars;\n Helpers0 = Helpers0 && Object.prototype.hasOwnProperty.call(Helpers0, 'default') ? Helpers0['default'] : Helpers0;\n iframeNotifier = iframeNotifier && Object.prototype.hasOwnProperty.call(iframeNotifier, 'default') ? iframeNotifier['default'] : iframeNotifier;\n\n if (!Helpers0.__initialized) {\n Helpers0(Handlebars);\n Helpers0.__initialized = true;\n }\n var Template = Handlebars.template(function (Handlebars,depth0,helpers,partials,data) {\n this.compilerInfo = [4,'>= 1.0.0'];\n helpers = this.merge(helpers, Handlebars.helpers); data = data || {};\n var buffer = \"\", helper, options, helperMissing=helpers.helperMissing, escapeExpression=this.escapeExpression;\n\n\n buffer += \"
  • \\n \\n \"\n + escapeExpression((helper = helpers.__ || (depth0 && depth0.__),options={hash:{},data:data},helper ? helper.call(depth0, \"OK\", options) : helperMissing.call(depth0, \"__\", \"OK\", options)))\n + \"\\n \\n
  • \";\n return buffer;\n });\n function previewOkBtn(data, options, asString) {\n var html = Template(data, options);\n return (asString || true) ? html : $(html);\n }\n\n if (!Helpers0.__initialized) {\n Helpers0(Handlebars);\n Helpers0.__initialized = true;\n }\n var Template$1 = Handlebars.template(function (Handlebars,depth0,helpers,partials,data) {\n this.compilerInfo = [4,'>= 1.0.0'];\n helpers = this.merge(helpers, Handlebars.helpers); \n\n\n return \"
  • \\n \\n \\n OK\\n \\n
  • \";\n });\n function deliveryOkBtn(data, options, asString) {\n var html = Template$1(data, options);\n return (asString || true) ? html : $(html);\n }\n\n /*\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2015 (original work) Open Assessment Techonologies SA;\n *\n */\n\n var timeout = (context.timeout > 0 ? context.timeout + 1 : 30) * 1000;\n\n /**\n * Main function for the module. It loads and render the feedbacks accodring to the given itemSession variables\n *\n * @param {Object} item - the standard tao qti item object\n * @param {Object} loader - the item loader instance\n * @param {Object} renderer - the item render instance\n * @param {Object} itemSession - session information containing the list of feedbacks to display\n * @param {Function} onCloseCallback - the callback to be executed when the feedbacks are closed\n * @param {Function} [onShowCallback] - the callback to be executed when the feedbacks are shown\n * @returns {Number} Number of feedbacks to be displayed\n */\n function showFeedbacks(item, loader, renderer, itemSession, onCloseCallback, onShowCallback) {\n var interactionsDisplayInfo = getInteractionsDisplayInfo(item);\n var messages = {};\n var renderedFeebacks = [];\n var renderingQueue = [];\n var $itemContainer = item.getContainer();\n var $itemBody = $itemContainer.children('.qti-itemBody');\n var firstFeedback;\n\n _.each(item.modalFeedbacks, function(feedback) {\n var feedbackIds, message, $container, comparedOutcome, _currentMessageGroupId, interactionInfo;\n var outcomeIdentifier = feedback.attr('outcomeIdentifier');\n var order = -1;\n\n //verify if the feedback should be displayed\n if (itemSession[outcomeIdentifier]) {\n //is the feedback in the list of feedbacks to be displayed ?\n feedbackIds = pci.getRawValues(itemSession[outcomeIdentifier]);\n if (_.indexOf(feedbackIds, feedback.id()) === -1) {\n return true; //continue with next feedback\n }\n\n //which group of feedbacks (interaction related) the feedback belongs to ?\n message = getFeedbackMessageSignature(feedback);\n comparedOutcome = containerHelper.getEncodedData(feedback, 'relatedOutcome');\n interactionInfo = _.find(interactionsDisplayInfo, { responseIdentifier: comparedOutcome });\n if (comparedOutcome && interactionInfo) {\n $container = interactionInfo.displayContainer;\n _currentMessageGroupId = interactionInfo.messageGroupId;\n order = interactionInfo.order;\n } else {\n $container = $itemBody;\n _currentMessageGroupId = '__item__';\n }\n //is this message already displayed ?\n if (!messages[_currentMessageGroupId]) {\n messages[_currentMessageGroupId] = [];\n }\n if (_.indexOf(messages[_currentMessageGroupId], message) >= 0) {\n return true; //continue\n } else {\n messages[_currentMessageGroupId].push(message);\n }\n\n //ok, display feedback\n renderingQueue.push({\n feedback: feedback,\n $container: $container,\n order: order\n });\n }\n });\n\n if (renderingQueue.length) {\n renderingQueue = _.sortBy(renderingQueue, 'order');\n\n //clear previously displayed feedbacks\n clearModalFeedbacks($itemContainer);\n\n //process rendering queue\n _.each(renderingQueue, function(renderingToken) {\n renderModalFeedback(\n renderingToken.feedback,\n loader,\n renderer,\n renderingToken.$container,\n $itemContainer,\n function(renderingData) {\n // keep the first feedback to force focus on it if needed\n if (!firstFeedback) {\n firstFeedback = $$1(renderingData.dom);\n }\n\n $$1('img', renderingData.dom).on('load', function() {\n iframeNotifier.parent('itemcontentchange');\n });\n\n //record rendered feedback for later reference\n renderedFeebacks.push(renderingData);\n if (renderedFeebacks.length === renderingQueue.length) {\n //rendering processing queue completed\n iframeNotifier.parent('itemcontentchange');\n\n // set the focus on the first feedback if needed\n // TODO: this is heavily related to the old TestRunner, with the ugly iframes.\n // To make this working, a search is made accross parent frames.\n // When the InlineFeedbacks will be ported to the new TestRunner, a strong improvement will be needed!\n if (firstFeedback) {\n autoscroll(firstFeedback);\n }\n\n //if an optional \"on show modal\" callback has been provided, execute it\n if (_.isFunction(onShowCallback)) {\n onShowCallback();\n }\n }\n }\n );\n });\n\n //if any feedback is displayed, replace the controls by a \"ok\" button\n replaceControl(renderedFeebacks, $itemContainer, onCloseCallback);\n }\n\n return renderingQueue.length;\n }\n\n /**\n * Gets the QTI Container element\n * @returns {jQuery|null}\n */\n function getQtiContainer() {\n var me = window;\n var $container = null;\n var max = 10;\n\n while (me && me.__knownParent__ && max--) {\n me = me.parent;\n if (me && me.$) {\n $container = me.$('#qti-content');\n if ($container.length) {\n return $container;\n }\n }\n }\n return null;\n }\n\n /**\n * Keeps an element visible inside the QTI container.\n * If the element is outside the container viewport, scroll to display it.\n * @param {String|jQuery|HTMLElement} element\n */\n function autoscroll(element) {\n var $element = $$1(element);\n var $container = getQtiContainer();\n var currentScrollTop, minScrollTop, maxScrollTop, scrollTop;\n\n if ($element.length && $container) {\n currentScrollTop = $container.scrollTop();\n maxScrollTop = $element.offset().top;\n minScrollTop = maxScrollTop - $container.height() + $element.outerHeight();\n scrollTop = Math.max(Math.min(maxScrollTop, currentScrollTop), minScrollTop);\n if (scrollTop !== currentScrollTop) {\n $container.animate({ scrollTop: scrollTop });\n }\n }\n }\n\n /**\n * Extract the display information for an interaction-related feedback\n *\n * @private\n * @param {Object} interaction - a qti interaction object\n * @returns {Object} Object containing useful display information\n */\n function extractDisplayInfo(interaction) {\n var $interactionContainer = interaction.getContainer();\n var responseIdentifier = interaction.attr('responseIdentifier');\n var messageGroupId, $displayContainer;\n\n if (interaction.is('inlineInteraction')) {\n $displayContainer = $interactionContainer.closest('[class*=\" col-\"], [class^=\"col-\"]');\n messageGroupId = $displayContainer.attr('data-messageGroupId');\n if (!messageGroupId) {\n //generate a messageFroupId\n messageGroupId = _.uniqueId('inline_message_group_');\n $displayContainer.attr('data-messageGroupId', messageGroupId);\n }\n } else {\n messageGroupId = responseIdentifier;\n $displayContainer = $interactionContainer;\n }\n\n return {\n responseIdentifier: responseIdentifier,\n interactionContainer: $interactionContainer,\n displayContainer: $displayContainer,\n messageGroupId: messageGroupId,\n order: -1\n };\n }\n\n /**\n * Get interaction display information sorted in the order of appearance within the item\n *\n * @param {Object} item\n * @returns {Array}\n */\n function getInteractionsDisplayInfo(item) {\n var interactionsDisplayInfo = [];\n var $itemContainer = item.getContainer();\n var interactionOrder = 0;\n\n //extract all interction related information needed to display their\n _.each(item.getComposingElements(), function(element) {\n var responseIdentifier;\n if (element.is('interaction')) {\n responseIdentifier = element.attr('responseIdentifier');\n interactionsDisplayInfo.push(extractDisplayInfo(element));\n }\n });\n\n //sort interactionsDisplayInfo on the item level\n $itemContainer.find('.qti-interaction').each(function() {\n var interactionContainer = this;\n _.each(interactionsDisplayInfo, function(_interactionInfo) {\n if (_interactionInfo.interactionContainer[0] === interactionContainer) {\n _interactionInfo.order = interactionOrder;\n return false;\n }\n });\n interactionOrder++;\n });\n interactionsDisplayInfo = _.sortBy(interactionsDisplayInfo, 'order');\n\n return interactionsDisplayInfo;\n }\n\n /**\n * Remove previously displayed feedbacks contained in the given container element\n *\n * @param {JQuery} $itemContainer\n */\n function clearModalFeedbacks($itemContainer) {\n $itemContainer.find('.qti-modalFeedback').remove();\n }\n\n /**\n * Render a modal feedback into a given container, scoped within an item container\n *\n * @private\n * @param {type} feedback - feedback object\n * @param {type} loader - loader instance\n * @param {type} renderer - renderer instance\n * @param {JQuery} $container - the targeted feedback container\n * @param {JQuery} $itemContainer - the item container\n * @param {type} renderedCallback - callback when the feedback has been rendered\n * @returns {undefined}\n */\n function renderModalFeedback(feedback, loader, renderer, $container, $itemContainer, renderedCallback) {\n //load (potential) new qti classes used in the modal feedback (e.g. math, img)\n renderer.load(function() {\n //render the modal feedback\n var $modalFeedback = $$1(\n feedback.render({\n inline: true\n })\n );\n var done = function done() {\n renderedCallback({\n identifier: feedback.id(),\n serial: feedback.getSerial(),\n dom: $modalFeedback\n });\n };\n $container.append($modalFeedback);\n\n // Race between postRendering and timeout\n // postRendering waits for everything to be resolved or one reject\n Promise.race([\n Promise.all(\n _.map(feedback.getComposingElements(), function(elt) {\n //render also internal elements, such as math or img\n return elt.postRender({}, '', renderer).pop();\n })\n ),\n new Promise(function(resolve, reject) {\n _.delay(reject, timeout, new Error('Post rendering ran out of time.'));\n })\n ])\n .then(done)\n .catch(function(err) {\n //in case of postRendering issue, we are also done\n done();\n throw new Error('Error in post rendering : ' + err);\n });\n }, loader.getLoadedClasses());\n }\n\n /**\n * Replace the controls in the running environment with an \"OK\" button to trigger the end of the feedback state\n *\n * @private\n * @todo FIX ME ! replace the hack to preview and delivery toolbar with a proper plugin in the new test runner is ready\n * @param {Array} renderedFeebacks\n * @param {JQuery} $itemContainer\n * @param {Function} callback\n */\n function replaceControl(renderedFeebacks, $itemContainer, callback) {\n var $scope, $controls, $toggleContainer;\n if (window.parent && window.parent.parent && window.parent.parent.$) {\n if ($itemContainer.parents('.tao-preview-scope').length) {\n //preview mode\n $scope = window.parent.parent.$('#preview-console');\n $controls = $scope.find('.preview-console-header .action-bar li:visible');\n $toggleContainer = $scope.find('.console-button-action-bar');\n initControlToggle(renderedFeebacks, $itemContainer, $controls, $toggleContainer, previewOkBtn, callback);\n } else {\n //delivery delivery\n $scope = window.parent.parent.$('body.qti-test-scope .bottom-action-bar');\n $controls = $scope.find('li:visible');\n $toggleContainer = $scope.find('.navi-box-list');\n initControlToggle(renderedFeebacks, $itemContainer, $controls, $toggleContainer, deliveryOkBtn, callback);\n }\n } else {\n //not in an iframe, add to item body for now\n $scope = $itemContainer.find('#modalFeedbacks');\n initControlToggle(renderedFeebacks, $itemContainer, $$1(), $scope, previewOkBtn, callback);\n }\n }\n\n /**\n * Initialize the \"OK\" button to trigger the end of the feedback mode\n *\n * @private\n * @param {Array} renderedFeebacks\n * @param {JQuery} $itemContainer\n * @param {JQuery} $controls\n * @param {JQuery} $toggleContainer\n * @param {Function} toggleButtonTemplate\n * @param {Function} callback\n */\n function initControlToggle(\n renderedFeebacks,\n $itemContainer,\n $controls,\n $toggleContainer,\n toggleButtonTemplate,\n callback\n ) {\n var $ok = $$1(toggleButtonTemplate()).click(function() {\n //end feedback mode, hide feedbacks\n _.each(renderedFeebacks, function(fb) {\n fb.dom.hide();\n });\n\n //restore controls\n uncover([$itemContainer]);\n $ok.remove();\n $controls.show();\n\n //exec callback\n callback();\n });\n\n $controls.hide();\n $toggleContainer.append($ok);\n cover([$itemContainer]);\n }\n\n /**\n * Cover the given interaction containers with a transparent layer to prevent user interacting with the item\n * @private\n * @param {Array} interactionContainers\n */\n function cover(interactionContainers) {\n var $cover = $$1('
    ');\n _.each(interactionContainers, function($interaction) {\n $interaction.append($cover);\n });\n }\n\n /**\n * Remove the layer set by the function cover()\n * @private\n * @param {Array} interactionContainers\n */\n function uncover(interactionContainers) {\n _.each(interactionContainers, function($interaction) {\n $interaction.find('.interaction-cover').remove();\n });\n }\n\n /**\n * Provide the feedbackMessage signature to check if the feedback contents should be considered equals\n *\n * @param {type} feedback\n * @returns {String}\n */\n function getFeedbackMessageSignature(feedback) {\n return ('' + feedback.body() + feedback.attr('title'))\n .toLowerCase()\n .trim()\n .replace(/x-tao-[a-zA-Z0-9\\-._\\s]*/g, '');\n }\n\n var inlineRenderer = {\n showFeedbacks: showFeedbacks\n };\n\n return inlineRenderer;\n\n});\n\n","define('taoQtiItem/qtiRunner/modalFeedback/modalRenderer',['lodash', 'jquery', 'async', 'taoQtiItem/qtiItem/helper/pci'], function (_, $, async, pci) { 'use strict';\n\n _ = _ && Object.prototype.hasOwnProperty.call(_, 'default') ? _['default'] : _;\n $ = $ && Object.prototype.hasOwnProperty.call($, 'default') ? $['default'] : $;\n async = async && Object.prototype.hasOwnProperty.call(async, 'default') ? async['default'] : async;\n pci = pci && Object.prototype.hasOwnProperty.call(pci, 'default') ? pci['default'] : pci;\n\n /*\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2015 (original work) Open Assessment Techonologies SA;\n *\n */\n\n /**\n * Main function for the module. It loads and render the feedbacks accodring to the given itemSession variables\n *\n * @param {Object} item - the standard tao qti item object\n * @param {Object} loader - the item loader instance\n * @param {Object} renderer - the item render instance\n * @param {Object} itemSession - session information containing the list of feedbacks to display\n * @param {Function} onCloseCallback - the callback to be executed when the feedbacks are closed\n * @param {Function} [onShowCallback] - the callback to be executed when the feedbacks are shown\n * @returns {Number} Number of feedbacks to be displayed\n */\n function showFeedbacks(item, loader, renderer, itemSession, onCloseCallback, onShowCallback) {\n var count,\n messages = [],\n feedbacksToBeDisplayed = [];\n\n //find which modal feedbacks should be displayed according to the current item session:\n _.each(item.modalFeedbacks, function(feedback) {\n var feedbackIds, message;\n var outcomeIdentifier = feedback.attr('outcomeIdentifier');\n\n if (itemSession[outcomeIdentifier]) {\n feedbackIds = pci.getRawValues(itemSession[outcomeIdentifier]);\n message = getFeedbackMessageSignature(feedback);\n if (_.indexOf(feedbackIds, feedback.id()) >= 0 && _.indexOf(messages, message) === -1) {\n //check content if is already in the display queue\n feedbacksToBeDisplayed.push(feedback);\n messages.push(message);\n }\n }\n });\n\n //record the number of feedbacks to be displayed:\n count = feedbacksToBeDisplayed.length;\n if (count) {\n //show in reverse order\n var callstack = [];\n\n //iterate from the right because the modal popup will pile up.\n _.eachRight(feedbacksToBeDisplayed, function(feedback) {\n //the end callback should be executed to the last displayed modal, which is the last displayed one\n var endCallback;\n if (callstack.length === 0) {\n endCallback = function() {\n onCloseCallback();\n };\n }\n\n callstack.push(function(cb) {\n renderModalFeedback(\n feedback,\n loader,\n renderer,\n function() {\n cb(null);\n },\n endCallback\n );\n });\n });\n\n async.series(callstack, function() {\n //all modal are ready and displayed\n if (_.isFunction(onShowCallback)) {\n onShowCallback();\n }\n });\n }\n\n return count;\n }\n\n /**\n * Render modal feedback as a modal popup\n *\n * @param {Object} feedback - object\n * @param {Object} loader - loader instance\n * @param {Object} renderer - renderer instance\n * @param {Function} [closeCallback] - feedback to be executed when the popop closes\n * @returns {undefined}\n */\n function renderModalFeedback(feedback, loader, renderer, renderedCallback, closeCallback) {\n var $feedback,\n $feedbackBox = $('#modalFeedbacks'); //feedback.getItem().getContainer().find('#')\n\n if (feedback.is('modalFeedback')) {\n //load (potential) new qti classes used in the modal feedback (e.g. math, img)\n renderer.load(function() {\n $feedback = $feedbackBox.find('#' + feedback.getSerial());\n if (!$feedback.length) {\n //render the modal feedback\n $feedback = feedback.render();\n $feedbackBox.append($feedback);\n } else {\n $feedback.modal();\n }\n\n renderedCallback();\n\n feedback.postRender({\n callback: closeCallback\n });\n }, loader.getLoadedClasses());\n }\n }\n\n /**\n * Provide the feedbackMessage signature to check if the feedback contents should be considered equals\n *\n * @param {type} feedback\n * @returns {String}\n */\n function getFeedbackMessageSignature(feedback) {\n return ('' + feedback.body() + feedback.attr('title'))\n .toLowerCase()\n .trim()\n .replace(/x-tao-[a-zA-Z0-9\\-._\\s]*/g, '');\n }\n\n var modalRenderer = {\n showFeedbacks: showFeedbacks\n };\n\n return modalRenderer;\n\n});\n\n","define('taoQtiItem/qtiRunner/core/QtiRunner',['jquery', 'lodash', 'context', 'module', 'iframeNotifier', 'taoQtiItem/qtiItem/core/Loader', 'taoQtiItem/qtiRunner/modalFeedback/inlineRenderer', 'taoQtiItem/qtiRunner/modalFeedback/modalRenderer'], function ($, _, context, module, iframeNotifier, ItemLoader, modalFeedbackInline, modalFeedbackModal) { 'use strict';\n\n $ = $ && Object.prototype.hasOwnProperty.call($, 'default') ? $['default'] : $;\n _ = _ && Object.prototype.hasOwnProperty.call(_, 'default') ? _['default'] : _;\n context = context && Object.prototype.hasOwnProperty.call(context, 'default') ? context['default'] : context;\n module = module && Object.prototype.hasOwnProperty.call(module, 'default') ? module['default'] : module;\n iframeNotifier = iframeNotifier && Object.prototype.hasOwnProperty.call(iframeNotifier, 'default') ? iframeNotifier['default'] : iframeNotifier;\n ItemLoader = ItemLoader && Object.prototype.hasOwnProperty.call(ItemLoader, 'default') ? ItemLoader['default'] : ItemLoader;\n modalFeedbackInline = modalFeedbackInline && Object.prototype.hasOwnProperty.call(modalFeedbackInline, 'default') ? modalFeedbackInline['default'] : modalFeedbackInline;\n modalFeedbackModal = modalFeedbackModal && Object.prototype.hasOwnProperty.call(modalFeedbackModal, 'default') ? modalFeedbackModal['default'] : modalFeedbackModal;\n\n /*\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2013 (original work) Open Assessment Techonologies SA (under the project TAO-PRODUCT);\n *\n *\n */\n\n var timeout = (context.timeout > 0 ? context.timeout + 1 : 30) * 1000;\n\n var QtiRunner = function() {\n this.item = null;\n this.rpEngine = null;\n this.renderer = null;\n this.loader = null;\n this.itemApi = undefined;\n };\n\n QtiRunner.prototype.updateItemApi = function() {\n var responses = this.getResponses();\n var states = this.getStates();\n var variables = [];\n // Transform responses into state variables.\n for (var key in states) {\n var value = states[key];\n // This is where we set variables that will be collected and stored\n // as the Item State. We do not want to store large files into\n // the state, and force the client to download these files\n // all over again. We then transform them as a place holder, that will\n // simply indicate that a file composes the state.\n\n if (value.response && typeof value.response.base !== 'undefined') {\n for (var property in value.response.base) {\n if (property === 'file') {\n var file = value.response.base.file;\n // QTI File found! Replace it with an appropriate placeholder.\n // The data is base64('qti_file_datatype_placeholder_data')\n value.response = {\n base: {\n file: {\n name: file.name,\n mime: 'qti+application/octet-stream',\n data: 'cXRpX2ZpbGVfZGF0YXR5cGVfcGxhY2Vob2xkZXJfZGF0YQ=='\n }\n }\n };\n }\n }\n }\n\n variables[key] = value;\n }\n\n //set all variables at once\n this.itemApi.setVariables(variables);\n\n // Save the responses that will be used for response processing.\n this.itemApi.saveResponses(responses);\n this.itemApi.resultApi.setQtiRunner(this);\n };\n\n QtiRunner.prototype.setItemApi = function(itemApi) {\n this.itemApi = itemApi;\n var that = this;\n var oldStateVariables = JSON.stringify(itemApi.stateVariables);\n\n itemApi.onKill(function(killCallback) {\n // If the responses did not change,\n // just close gracefully.\n\n // Collect new responses and update item API.\n that.updateItemApi();\n var newStateVariables = JSON.stringify(itemApi.stateVariables);\n\n // Store the results.\n if (oldStateVariables !== newStateVariables || itemApi.serviceApi.getHasBeenPaused()) {\n itemApi.submit(function() {\n // Send successful signal.\n itemApi.serviceApi.setHasBeenPaused(false);\n killCallback(0);\n });\n } else {\n killCallback(0);\n }\n });\n };\n\n QtiRunner.prototype.setRenderer = function(renderer) {\n if (renderer.isRenderer) {\n this.renderer = renderer;\n } else {\n throw 'invalid renderer';\n }\n };\n\n QtiRunner.prototype.getLoader = function() {\n if (!this.loader) {\n this.loader = new ItemLoader();\n }\n return this.loader;\n };\n\n QtiRunner.prototype.loadItemData = function(data, callback) {\n var self = this;\n this.getLoader().loadItemData(data, function(item) {\n self.item = item;\n callback(self.item);\n });\n };\n\n QtiRunner.prototype.loadElements = function(elements, callback) {\n if (this.getLoader().item) {\n this.getLoader().loadElements(elements, callback);\n } else {\n throw 'QtiRunner : cannot load elements in empty item';\n }\n };\n\n QtiRunner.prototype.renderItem = function(data, done) {\n var self = this;\n\n done = _.isFunction(done) ? done : _.noop;\n\n var render = function() {\n if (!self.item) {\n throw 'cannot render item: empty item';\n }\n if (self.renderer) {\n self.renderer.load(function() {\n self.item.setRenderer(self.renderer);\n self.item.render({}, $('#qti_item'));\n\n // Race between postRendering and timeout\n // postRendering waits for everything to be resolved or one reject\n Promise.race([\n Promise.all(self.item.postRender()),\n new Promise(function(resolve, reject) {\n _.delay(reject, timeout, new Error('Post rendering ran out of time.'));\n })\n ])\n .then(function() {\n self.item.getContainer().on('responseChange', function(e, data) {\n if (data.interaction && data.interaction.attr('responseIdentifier') && data.response) {\n iframeNotifier.parent('responsechange', [\n data.interaction.attr('responseIdentifier'),\n data.response\n ]);\n }\n });\n\n self.initInteractionsResponse();\n self.listenForThemeChange();\n done();\n })\n .catch(function(err) {\n //in case of postRendering issue, we are also done\n done();\n\n throw new Error('Error in post rendering : ' + err);\n });\n }, self.getLoader().getLoadedClasses());\n } else {\n throw 'cannot render item: no rendered set';\n }\n };\n\n if (typeof data === 'object') {\n this.loadItemData(data, render);\n } else {\n render();\n }\n };\n\n QtiRunner.prototype.initInteractionsResponse = function() {\n var self = this;\n if (self.item) {\n var interactions = self.item.getInteractions();\n for (var i in interactions) {\n var interaction = interactions[i];\n var responseId = interaction.attr('responseIdentifier');\n self.itemApi.getVariable(responseId, function(values) {\n if (values) {\n interaction.setState(values);\n iframeNotifier.parent('stateready', [responseId, values]);\n } else {\n var states = self.getStates();\n if (_.indexOf(states, responseId)) {\n self.itemApi.setVariable(responseId, states[responseId]);\n interaction.setState(states[responseId]);\n iframeNotifier.parent('stateready', [responseId, states[responseId]]);\n }\n }\n });\n }\n }\n };\n\n /**\n * If an event 'themechange' bubbles to \"#qti_item\" node\n * then we tell the renderer to switch the theme.\n */\n QtiRunner.prototype.listenForThemeChange = function listenForThemeChange() {\n var self = this;\n var $container = this.renderer.getContainer(this.item);\n if (!$container.length) {\n $container = $('.qti-item');\n }\n $container.off('themechange').on('themechange', function(e, themeName) {\n var themeLoader = self.renderer.getThemeLoader();\n themeName = themeName || e.originalEvent.detail;\n if (themeLoader) {\n themeLoader.change(themeName);\n }\n });\n };\n\n QtiRunner.prototype.validate = function() {\n this.updateItemApi();\n this.itemApi.finish();\n };\n\n QtiRunner.prototype.getResponses = function() {\n var responses = {};\n var interactions = this.item.getInteractions();\n\n _.forEach(interactions, function(interaction) {\n var response = {};\n try {\n response = interaction.getResponse();\n } catch (e) {\n console.error(e);\n }\n responses[interaction.attr('responseIdentifier')] = response;\n });\n\n return responses;\n };\n\n QtiRunner.prototype.getStates = function() {\n var states = {};\n var interactions = this.item.getInteractions();\n\n _.forEach(interactions, function(interaction) {\n var state = {};\n try {\n state = interaction.getState();\n } catch (e) {\n console.error(e);\n }\n states[interaction.attr('responseIdentifier')] = state;\n });\n\n return states;\n };\n\n QtiRunner.prototype.setResponseProcessing = function(callback) {\n this.rpEngine = callback;\n };\n\n QtiRunner.prototype.showFeedbacks = function(itemSession, callback, onShowCallback) {\n var inlineDisplay = !!module.config().inlineModalFeedback;\n\n //currently only modal feedbacks are available\n if (inlineDisplay) {\n return modalFeedbackInline.showFeedbacks(\n this.item,\n this.getLoader(),\n this.renderer,\n itemSession,\n callback,\n onShowCallback\n );\n } else {\n return modalFeedbackModal.showFeedbacks(\n this.item,\n this.getLoader(),\n this.renderer,\n itemSession,\n callback,\n onShowCallback\n );\n }\n };\n\n return QtiRunner;\n\n});\n\n","define('taoQtiItem/qtiItem/helper/interactionHelper',['lodash', 'taoQtiItem/qtiItem/core/Element'], function (_, Element) { 'use strict';\n\n _ = _ && Object.prototype.hasOwnProperty.call(_, 'default') ? _['default'] : _;\n Element = Element && Object.prototype.hasOwnProperty.call(Element, 'default') ? Element['default'] : Element;\n\n /**\n * Common helper functions\n */\n var interactionHelper = {\n convertChoices: function(choices, outputType) {\n var ret = [],\n _this = this;\n\n _.each(choices, function(c) {\n if (Element.isA(c, 'choice')) {\n switch (outputType) {\n case 'serial':\n ret.push(c.getSerial());\n break;\n case 'identifier':\n ret.push(c.id());\n break;\n default:\n ret.push(c);\n }\n } else if (_.isArray(c)) {\n ret.push(_this.convertChoices(c, outputType));\n }\n });\n\n return ret;\n },\n findChoices: function(interaction, choices, inputType) {\n var ret = [],\n _this = this;\n\n _.each(choices, function(c) {\n var choice;\n if (_.isString(c)) {\n if (inputType === 'serial') {\n choice = interaction.getChoice(c);\n if (choice) {\n ret.push(choice);\n }\n } else if (inputType === 'identifier') {\n choice = interaction.getChoiceByIdentifier(c);\n if (choice) {\n ret.push(choice);\n }\n } else {\n ret.push(c);\n }\n } else if (_.isArray(c)) {\n ret.push(_this.findChoices(interaction, c, inputType));\n } else {\n ret.push(c);\n }\n });\n\n return ret;\n },\n shuffleChoices: function(choices) {\n var r = [], //returned array\n f = {}, //fixed choices array\n j = 0;\n\n for (var i in choices) {\n if (Element.isA(choices[i], 'choice')) {\n var choice = choices[i];\n if (choice.attr('fixed')) {\n f[j] = choice;\n }\n r.push(choice);\n j++;\n } else {\n throw 'invalid element in array: is not a qti choice';\n }\n }\n\n for (var n = 0; n < r.length - 1; n++) {\n if (f[n]) {\n continue;\n }\n var k = -1;\n do {\n k = n + Math.floor(Math.random() * (r.length - n));\n } while (f[k]);\n var tmp = r[k];\n r[k] = r[n];\n r[n] = tmp;\n }\n\n return r;\n },\n serialToIdentifier: function(interaction, choiceSerial) {\n var choice = interaction.getChoice(choiceSerial);\n if (choice) {\n return choice.id();\n } else {\n return '';\n }\n }\n };\n\n return interactionHelper;\n\n});\n\n","define('taoQtiItem/qtiRunner/core/Renderer',['lodash', 'jquery', 'taoQtiItem/qtiItem/core/Element', 'taoQtiItem/qtiItem/helper/interactionHelper', 'ui/themeLoader', 'ui/themes', 'core/moduleLoader', 'handlebars'], function (_, $, Element, interactionHelper, themeLoader, themesHelper, moduleLoader, Handlebars) { 'use strict';\n\n _ = _ && Object.prototype.hasOwnProperty.call(_, 'default') ? _['default'] : _;\n $ = $ && Object.prototype.hasOwnProperty.call($, 'default') ? $['default'] : $;\n Element = Element && Object.prototype.hasOwnProperty.call(Element, 'default') ? Element['default'] : Element;\n interactionHelper = interactionHelper && Object.prototype.hasOwnProperty.call(interactionHelper, 'default') ? interactionHelper['default'] : interactionHelper;\n themeLoader = themeLoader && Object.prototype.hasOwnProperty.call(themeLoader, 'default') ? themeLoader['default'] : themeLoader;\n themesHelper = themesHelper && Object.prototype.hasOwnProperty.call(themesHelper, 'default') ? themesHelper['default'] : themesHelper;\n moduleLoader = moduleLoader && Object.prototype.hasOwnProperty.call(moduleLoader, 'default') ? moduleLoader['default'] : moduleLoader;\n Handlebars = Handlebars && Object.prototype.hasOwnProperty.call(Handlebars, 'default') ? Handlebars['default'] : Handlebars;\n\n /*\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2014-2022 (original work) Open Assessment Technlogies SA (under the project TAO-PRODUCT);\n *\n */\n\n //webpack trick : handlebar is usale only from cjs.\n //but anyway we should deprecate the practice to invoke\n //directly Handlebars at runtimej\n let hb = Handlebars;\n if(typeof hb.compile !== 'function'){\n hb = require('handlebars');\n }\n\n const _renderableClasses = [\n '_container',\n 'assessmentItem',\n 'stylesheet',\n 'responseDeclaration',\n 'outcomeDeclaration',\n 'responseProcessing',\n '_simpleFeedbackRule',\n '_tooltip',\n 'figure',\n 'img',\n 'figcaption',\n 'math',\n 'object',\n 'table',\n 'modalFeedback',\n 'rubricBlock',\n 'associateInteraction',\n 'choiceInteraction',\n 'extendedTextInteraction',\n 'gapMatchInteraction',\n 'graphicAssociateInteraction',\n 'graphicGapMatchInteraction',\n 'graphicOrderInteraction',\n 'hotspotInteraction',\n 'hottextInteraction',\n 'inlineChoiceInteraction',\n 'matchInteraction',\n 'mediaInteraction',\n 'orderInteraction',\n 'selectPointInteraction',\n 'sliderInteraction',\n 'textEntryInteraction',\n 'uploadInteraction',\n 'endAttemptInteraction',\n 'customInteraction',\n 'prompt',\n 'associableHotspot',\n 'gap',\n 'gapImg',\n 'gapText',\n 'hotspotChoice',\n 'hottext',\n 'inlineChoice',\n 'simpleAssociableChoice',\n 'simpleChoice',\n 'infoControl',\n 'include',\n 'printedVariable'\n ];\n\n /**\n * The list of qti element dependencies. It is used internally to load dependent qti classes\n */\n const _dependencies = {\n assessmentItem: ['stylesheet', '_container', 'prompt', 'modalFeedback'],\n rubricBlock: ['_container'],\n associateInteraction: ['simpleAssociableChoice'],\n choiceInteraction: ['simpleChoice'],\n gapMatchInteraction: ['gap', 'gapText'],\n graphicAssociateInteraction: ['associableHotspot'],\n graphicGapMatchInteraction: ['associableHotspot', 'gapImg'],\n graphicOrderInteraction: ['hotspotChoice'],\n hotspotInteraction: ['hotspotChoice'],\n hottextInteraction: ['hottext'],\n inlineChoiceInteraction: ['inlineChoice'],\n matchInteraction: ['simpleAssociableChoice'],\n orderInteraction: ['simpleChoice']\n };\n\n /**\n * The list of supported qti subclasses.\n */\n const _renderableSubclasses = {\n simpleAssociableChoice: ['associateInteraction', 'matchInteraction'],\n simpleChoice: ['choiceInteraction', 'orderInteraction']\n };\n\n /**\n * List of the default properties for the item\n */\n const _defaults = {\n shuffleChoices: true\n };\n\n const _isValidRenderer = function(renderer) {\n let valid = true;\n\n if (typeof renderer !== 'object') {\n return false;\n }\n\n let classCorrect = false;\n if (renderer.qtiClass) {\n if (_.indexOf(_renderableClasses, renderer.qtiClass) >= 0) {\n classCorrect = true;\n } else {\n const pos = renderer.qtiClass.indexOf('.');\n if (pos > 0) {\n const qtiClass = renderer.qtiClass.slice(0, pos);\n const subClass = renderer.qtiClass.slice(pos + 1);\n if (_renderableSubclasses[qtiClass] && _.indexOf(_renderableSubclasses[qtiClass], subClass) >= 0) {\n classCorrect = true;\n }\n }\n }\n }\n if (!classCorrect) {\n valid = false;\n throw new Error('invalid qti class name in renderer declaration : ' + renderer.qtiClass);\n }\n\n if (!renderer.template) {\n valid = false;\n throw new Error('missing template in renderer declaration : ' + renderer.qtiClass);\n }\n\n return valid;\n };\n\n /**\n * Get the location of the document, useful to define a baseUrl for the required context\n * @returns {String}\n */\n function getDocumentBaseUrl() {\n return window.location.protocol + '//' + window.location.host + window.location.pathname.replace(/([^\\/]*)$/, '');\n }\n\n /**\n * The built Renderer class\n * @constructor\n * @param {Object} [options] - the renderer options\n * @param {AssetManager} [options.assetManager] - The renderer needs an AssetManager to resolve URLs (see {@link taoItems/assets/manager})\n * @param {Boolean} [options.shuffleChoices = true] - Does the renderer take care of the shuffling\n * @param {Object} [options.decorators] - to set up rendering decorator\n * @param {preRenderDecorator} [options.decorators.before] - to set up a pre decorator\n * @param {postRenderDecorator} [options.decorators.after] - to set up a post decorator\n */\n const Renderer = function(options) {\n /**\n * Store the registered renderer location\n */\n const _locations = {};\n\n /**\n * Store loaded renderers\n */\n const _renderers = {};\n\n options = _.defaults(options || {}, _defaults);\n\n this.isRenderer = true;\n\n this.name = '';\n\n //store shuffled choice here\n this.shuffledChoices = [];\n\n /**\n * Get the actual renderer of the give qti class or subclass:\n * e.g. simplceChoice, simpleChoice.choiceInteraction, simpleChoice.orderInteraction\n */\n const _getClassRenderer = function(qtiClass) {\n let ret = null;\n if (_renderers[qtiClass]) {\n ret = _renderers[qtiClass];\n } else {\n const pos = qtiClass.indexOf('.');\n if (pos > 0) {\n qtiClass = qtiClass.slice(0, pos);\n if (_renderers[qtiClass]) {\n ret = _renderers[qtiClass];\n }\n }\n }\n return ret;\n };\n\n /**\n * Registers a QTI renderer class\n * @param {String} qtiClass\n * @param {Array} list\n * @returns {Boolean} `true` if the class has been successfully registered\n */\n function registerRendererClass(qtiClass, list) {\n let success = false;\n if (_locations[qtiClass] === false) {\n //mark this class as not renderable\n _renderers[qtiClass] = false;\n success = true;\n } else if (_locations[qtiClass]) {\n list.push(_locations[qtiClass]);\n success = true;\n }\n return success;\n }\n\n /**\n * Set the renderer options\n * @param {String} key - the name of the option\n * @param {*} value - the option vallue\n * @returns {Renderer} for chaining\n */\n this.setOption = function(key, value) {\n if (typeof key === 'string') {\n options[key] = value;\n }\n return this;\n };\n\n /**\n * Set the renderer options\n * @param {Object} opts - the options\n * @returns {Renderer} for chaining\n */\n this.setOptions = function(opts) {\n options = _.extend(options, opts);\n return this;\n };\n\n /**\n * Get the renderer option\n * @param {String} key - the name of the option\n * @returns {*|null} the option vallue\n */\n this.getOption = function(key) {\n if (typeof key === 'string' && options[key]) {\n return options[key];\n }\n return null;\n };\n\n this.getCustomMessage = function getCustomMessage(elementName, messageKey) {\n const messages = this.getOption('messages');\n if (messages && elementName && messages[elementName] && _.isString(messages[elementName][messageKey])) {\n //currently not translatable but potentially could be if the need raises\n return hb.compile(messages[elementName][messageKey]);\n } else {\n return null;\n }\n };\n\n /**\n * Get the bound assetManager\n * @returns {AssetManager} the assetManager\n */\n this.getAssetManager = function getAssetManager() {\n return options.assetManager;\n };\n\n /**\n * Get the bound theme loader\n * @returns {Object} the themeLoader\n */\n this.getThemeLoader = function getThemeLoader() {\n return this.themeLoader;\n };\n\n /**\n * Renders the template\n * @param {Object} element - the QTI model element\n * @param {Object} data - the data to give to the template\n * @param {String} [qtiSubclass] - to get the render of the element subclass (when element's qtiClass is abstract)\n * @returns {String} the template results\n * @throws {Error} if the renderer is not set or has no template bound\n */\n this.renderTpl = function(element, data, qtiSubclass) {\n let res;\n let ret = '';\n const qtiClass = qtiSubclass || element.qtiClass;\n const renderer = _getClassRenderer(qtiClass);\n const decorators = this.getOption('decorators');\n\n if (!renderer || !_.isFunction(renderer.template)) {\n throw new Error('no renderer template loaded under the class name : ' + qtiClass);\n }\n\n //pre rendering decoration\n if (_.isObject(decorators) && _.isFunction(decorators.before)) {\n /**\n * @callback preRenderDecoractor\n * @param {Object} element - the QTI model element\n * @param {String} [qtiSubclass] - to get the render of the element subclass (when element's qtiClass is abstract)\n * @returns {String} the decorator result\n */\n res = decorators.before(element, qtiSubclass);\n if (_.isString(res)) {\n ret += res;\n }\n }\n\n //render the template\n ret += renderer.template(data);\n\n //post rendering decoration\n if (_.isObject(decorators) && _.isFunction(decorators.after)) {\n /**\n * @callback postRenderDecoractor\n * @param {Object} element - the QTI model element\n * @param {String} [qtiSubclass] - to get the render of the element subclass (when element's qtiClass is abstract)\n * @returns {String} the decorator result\n */\n res = decorators.after(element, qtiSubclass);\n if (_.isString(res)) {\n ret += res;\n }\n }\n return ret;\n };\n\n this.getData = function(element, data, qtiSubclass) {\n let ret = data;\n const qtiClass = qtiSubclass || element.qtiClass;\n const renderer = _getClassRenderer(qtiClass);\n\n if (renderer) {\n if (typeof renderer.getData === 'function') {\n ret = renderer.getData.call(this, element, data);\n }\n }\n\n return ret;\n };\n\n this.renderDirect = function(tpl, data) {\n return hb.compile(tpl)(data);\n };\n\n this.getContainer = function(qtiElement, $scope, qtiSubclass) {\n let ret = null;\n const qtiClass = qtiSubclass || qtiElement.qtiClass;\n const renderer = _getClassRenderer(qtiClass);\n\n if (renderer) {\n ret = renderer.getContainer(qtiElement, $scope);\n } else {\n throw new Error('no renderer found for the class : ' + qtiElement.qtiClass);\n }\n return ret;\n };\n\n this.postRender = function(qtiElement, data, qtiSubclass) {\n const qtiClass = qtiSubclass || qtiElement.qtiClass;\n const renderer = _getClassRenderer(qtiClass);\n\n if (renderer && typeof renderer.render === 'function') {\n return renderer.render.call(this, qtiElement, data);\n }\n };\n\n this.setResponse = function(qtiInteraction, response, qtiSubclass) {\n let ret = false;\n const qtiClass = qtiSubclass || qtiInteraction.qtiClass;\n const renderer = _getClassRenderer(qtiClass);\n\n if (renderer) {\n if (typeof renderer.setResponse === 'function') {\n ret = renderer.setResponse.call(this, qtiInteraction, response);\n const $container = renderer.getContainer.call(this, qtiInteraction);\n if ($container instanceof $ && $container.length) {\n $container.trigger('responseSet', [qtiInteraction, response]);\n }\n }\n } else {\n throw new Error('no renderer registered under the name : ' + qtiClass);\n }\n return ret;\n };\n\n this.getResponse = function(qtiInteraction, qtiSubclass) {\n let ret = false;\n const qtiClass = qtiSubclass || qtiInteraction.qtiClass;\n const renderer = _getClassRenderer(qtiClass);\n\n if (renderer) {\n if (typeof renderer.getResponse === 'function') {\n ret = renderer.getResponse.call(this, qtiInteraction);\n }\n } else {\n throw new Error('no renderer registered under the name : ' + qtiClass);\n }\n return ret;\n };\n\n this.resetResponse = function(qtiInteraction, qtiSubclass) {\n let ret = false;\n const qtiClass = qtiSubclass || qtiInteraction.qtiClass;\n const renderer = _getClassRenderer(qtiClass);\n\n if (renderer) {\n if (typeof renderer.resetResponse === 'function') {\n ret = renderer.resetResponse.call(this, qtiInteraction);\n }\n } else {\n throw new Error('no renderer registered under the name : ' + qtiClass);\n }\n return ret;\n };\n\n /**\n * Retrieve the state of the interaction.\n * If the renderer has no state management, it falls back to the response management.\n *\n * @param {Object} qtiInteraction - the interaction\n * @param {String} [qtiSubClass] - (not sure of the type and how it is used - Sam ? )\n * @returns {Object} the interaction's state\n *\n * @throws {Error} if no renderer is registered\n */\n this.getState = function(qtiInteraction, qtiSubclass) {\n let ret = false;\n const qtiClass = qtiSubclass || qtiInteraction.qtiClass;\n const renderer = _getClassRenderer(qtiClass);\n\n if (renderer) {\n if (_.isFunction(renderer.getState)) {\n ret = renderer.getState.call(this, qtiInteraction);\n } else {\n ret = renderer.getResponse.call(this, qtiInteraction);\n }\n } else {\n throw new Error('no renderer registered under the name : ' + qtiClass);\n }\n return ret;\n };\n\n /**\n * Retrieve the state of the interaction.\n * If the renderer has no state management, it falls back to the response management.\n *\n * @param {Object} qtiInteraction - the interaction\n * @param {Object} state - the interaction's state\n * @param {String} [qtiSubClass] - (not sure of the type and how it is used - Sam ? )\n *\n * @throws {Error} if no renderer is found\n */\n this.setState = function(qtiInteraction, state, qtiSubclass) {\n const qtiClass = qtiSubclass || qtiInteraction.qtiClass;\n const renderer = _getClassRenderer(qtiClass);\n\n if (renderer) {\n if (_.isFunction(renderer.setState)) {\n renderer.setState.call(this, qtiInteraction, state);\n } else {\n renderer.resetResponse.call(this, qtiInteraction);\n renderer.setResponse.call(this, qtiInteraction, state);\n }\n } else {\n throw new Error('no renderer registered under the name : ' + qtiClass);\n }\n };\n\n /**\n * Calls the renderer destroy.\n * Ask the renderer to run destroy if exists.\n *\n * @throws {Error} if no renderer is found\n */\n this.destroy = function(qtiInteraction, qtiSubclass) {\n let ret = false;\n const qtiClass = qtiSubclass || qtiInteraction.qtiClass;\n const renderer = _getClassRenderer(qtiClass);\n\n if (renderer) {\n if (_.isFunction(renderer.destroy)) {\n ret = renderer.destroy.call(this, qtiInteraction);\n }\n } else {\n throw new Error('no renderer registered under the name : ' + qtiClass);\n }\n return ret;\n };\n\n this.getLoadedRenderers = function() {\n return _renderers;\n };\n\n this.register = function(renderersLocations) {\n _.extend(_locations, renderersLocations);\n };\n\n this.load = function(callback, requiredClasses) {\n const self = this;\n let required = [];\n\n const themeData = themesHelper.getCurrentThemeData();\n if (themeData) {\n options.themes = themeData;\n }\n if (options.themes) {\n //resolve themes paths\n options.themes.base = this.resolveUrl(options.themes.base);\n _.forEach(options.themes.available, function(theme, index) {\n options.themes.available[index].path = self.resolveUrl(theme.path);\n });\n this.themeLoader = themeLoader(options.themes).load(options.preload);\n }\n\n if (requiredClasses) {\n if (_.isArray(requiredClasses)) {\n //exclude abstract classes\n requiredClasses = _.intersection(requiredClasses, _renderableClasses);\n\n //add dependencies\n _.each(requiredClasses, function(reqClass) {\n const deps = _dependencies[reqClass];\n if (deps) {\n requiredClasses = _.union(requiredClasses, deps);\n }\n });\n\n _.forEach(requiredClasses, function(qtiClass) {\n let requiredSubClasses;\n if (_renderableSubclasses[qtiClass]) {\n requiredSubClasses = _.intersection(requiredClasses, _renderableSubclasses[qtiClass]);\n _.each(requiredSubClasses, function(subclass) {\n if (\n !registerRendererClass(qtiClass + '.' + subclass, required) &&\n !registerRendererClass(qtiClass, required)\n ) {\n throw new Error(\n self.name +\n ' : missing qti class location declaration: ' +\n qtiClass +\n ', subclass: ' +\n subclass\n );\n }\n });\n } else {\n if (!registerRendererClass(qtiClass, required)) {\n throw new Error(self.name + ' : missing qti class location declaration: ' + qtiClass);\n }\n }\n });\n } else {\n throw new Error('invalid argument type: expected array for arg \"requireClasses\"');\n }\n } else {\n required = _.values(_locations);\n }\n\n moduleLoader([], ()=> true)\n .addList( required.map( module => ({ module, category: 'qti'}) ) )\n .load()\n .then( loaded => {\n loaded.forEach( clazz => {\n if (_isValidRenderer(clazz)) {\n _renderers[clazz.qtiClass] = clazz;\n }\n\n });\n if (typeof callback === 'function') {\n callback.call(self, _renderers);\n }\n });\n\n return this;\n };\n\n /**\n * Unload the renderer\n */\n this.unload = function unload() {\n if (this.themeLoader) {\n themeLoader(options.themes).unload();\n }\n return this;\n };\n\n /**\n * Define the shuffling manually\n *\n * @param {Object} interaction - the interaction\n * @param {Array} choices - the shuffled choices\n * @param {String} identificationType -\n */\n this.setShuffledChoices = function(interaction, choices, identificationType) {\n if (Element.isA(interaction, 'interaction')) {\n this.shuffledChoices[interaction.getSerial()] = _.pluck(\n interactionHelper.findChoices(interaction, choices, identificationType),\n 'serial'\n );\n }\n };\n\n /**\n * Get the choices shuffled for this interaction.\n *\n * @param {Object} interaction - the interaction\n * @param {Boolean} reshuffle - by default choices are shuffled only once and store, but if true you can force shuffling again\n * @param {String} returnedType - the choice type\n * @returns {Array} the choices\n */\n this.getShuffledChoices = function(interaction, reshuffle, returnedType) {\n let choices = [];\n let serial, i;\n\n if (Element.isA(interaction, 'interaction')) {\n serial = interaction.getSerial();\n\n //1st time, we shuffle (or asked to force shuffling)\n if (!this.shuffledChoices[serial] || reshuffle) {\n if (Element.isA(interaction, 'matchInteraction')) {\n this.shuffledChoices[serial] = [];\n for (i = 0; i < 2; i++) {\n choices[i] = interactionHelper.shuffleChoices(interaction.getChoices(i));\n this.shuffledChoices[serial][i] = _.pluck(choices[i], 'serial');\n }\n } else {\n choices = interactionHelper.shuffleChoices(interaction.getChoices());\n this.shuffledChoices[serial] = _.pluck(choices, 'serial');\n }\n\n //otherwise get the choices from the serials\n } else {\n if (Element.isA(interaction, 'matchInteraction')) {\n _.forEach(choices, function(choice, index) {\n if (index < 2) {\n _.forEach(this.shuffledChoices[serial][i], function(choiceSerial) {\n choice.push(interaction.getChoice(choiceSerial));\n });\n }\n });\n } else {\n _.forEach(this.shuffledChoices[serial], function(choiceSerial) {\n choices.push(interaction.getChoice(choiceSerial));\n });\n }\n }\n\n //do some type convertion\n if (returnedType === 'serial' || returnedType === 'identifier') {\n return interactionHelper.convertChoices(choices, returnedType);\n }\n\n //pass value only, not ref\n return _.clone(choices);\n }\n\n return [];\n };\n\n this.getRenderers = function() {\n return _renderers;\n };\n\n this.getLocations = function() {\n return _locations;\n };\n\n /**\n * Resolve URLs using the defined assetManager's strategies\n * @param {String} url - the URL to resolve\n * @returns {String} the resolved URL\n */\n this.resolveUrl = function resolveUrl(url) {\n if (!options.assetManager) {\n return url;\n }\n if (typeof url === 'string' && url.length > 0) {\n return options.assetManager.resolve(url);\n }\n };\n\n /**\n * @deprecated in favor of resolveUrl\n */\n this.getAbsoluteUrl = function(relUrl) {\n //let until method is removed\n console.warn('DEPRECATED used getAbsoluteUrl with ', arguments);\n\n //allow relative url output only if explicitely said so\n if (this.getOption('userRelativeUrl')) {\n return relUrl.replace(/^\\.?\\//, '');\n }\n\n if (/^http(s)?:\\/\\//i.test(relUrl) || /^data:[^\\/]+\\/[^;]+(;charset=[\\w]+)?;base64,/.test(relUrl)) {\n //already absolute or base64 encoded\n return relUrl;\n } else {\n let absUrl = '';\n const runtimeLocations = this.getOption('runtimeLocations');\n\n if (runtimeLocations && _.size(runtimeLocations)) {\n _.forIn(runtimeLocations, function(runtimeLocation, typeIdentifier) {\n if (relUrl.indexOf(typeIdentifier) === 0) {\n absUrl = relUrl.replace(typeIdentifier, runtimeLocation);\n return false; //break\n }\n });\n }\n\n if (absUrl) {\n return absUrl;\n } else {\n const baseUrl = this.getOption('baseUrl') || getDocumentBaseUrl();\n return baseUrl + relUrl;\n }\n }\n };\n\n this.setAreaBroker = function setAreaBroker(areaBroker) {\n this._areaBroker = areaBroker;\n };\n\n this.getAreaBroker = function getAreaBroker() {\n if (this._areaBroker) {\n return this._areaBroker;\n }\n };\n\n this.getItemCreator = function getItemCreator() {\n return this.getOption('itemCreator');\n };\n };\n\n /**\n * Expose the renderer's factory\n * @exports taoQtiItem/qtiRunner/core/Renderer\n */\n var Renderer$1 = {\n /**\n * Creates a new Renderer by extending the Renderer's prototype\n * @param {Object} renderersLocations -\n * @param {String} [name] - the new renderer name\n * @param {Object} [defaultOptions] - the renderer options\n */\n build: function(renderersLocations, name, defaultOptions) {\n const NewRenderer = function() {\n const options = _.isPlainObject(arguments[0]) ? arguments[0] : {};\n\n Renderer.apply(this);\n\n this.register(renderersLocations);\n this.name = name || '';\n this.setOptions(_.defaults(options, defaultOptions || {}));\n };\n NewRenderer.prototype = Renderer.prototype;\n return NewRenderer;\n }\n };\n\n return Renderer$1;\n\n});\n\n","/*\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2016 (original work) Open Assessment Technologies SA;\n *\n */\ndefine('taoQtiItem/portableElementRegistry/factory/factory',['lodash', 'core/promise', 'core/eventifier'], function (_, Promise, eventifier){\n 'use strict';\n\n var _requirejs = window.require;\n var _defaultLoadingOptions = {\n reload: false\n };\n\n var loadModuleConfig = function loadModuleConfig(manifest){\n return new Promise(function(resolve, reject){\n var requireConfigAliases = {};\n var baseUrl;\n var reqConfigs = [];\n var modules = {};\n\n if(!manifest || !manifest.runtime){\n return reject('invalid manifest');\n }\n\n baseUrl = manifest.baseUrl;\n\n if(_.isArray(manifest.runtime.config) && manifest.runtime.config.length){\n _.forEach(manifest.runtime.config, function(pciConfig){\n if(_.isString(pciConfig)){\n reqConfigs.push('json!' + baseUrl + '/' + pciConfig);\n }else{\n if(pciConfig.data){\n modules = _.defaults(modules, pciConfig.data.paths || {});\n }else if(pciConfig.file){\n reqConfigs.push('json!' + baseUrl + '/' + pciConfig.file);\n }\n }\n });\n }\n\n require(reqConfigs, function(){\n\n var runtimeModules = {};\n\n requireConfigAliases[manifest.typeIdentifier] = baseUrl;\n\n if(manifest.model === 'IMSPCI'){\n\n modules = _.reduce(arguments, function(acc, conf){\n return _.defaults(acc, conf.paths || {});\n }, modules);\n\n _.forEach(manifest.runtime.modules || {}, function(paths, id){\n if(paths && (_.isString(paths) || (_.isArray(paths) && paths.length))){\n runtimeModules[id] = paths;\n }\n });\n\n modules = _.merge(modules, runtimeModules);\n\n _.forEach(modules, function(paths, id){\n paths = _.isArray(paths) ? paths : [paths];\n requireConfigAliases[id] = _.map(paths, function(path){\n return baseUrl+'/'+path.replace(/\\.js$/, '');\n });\n });\n }\n\n resolve(requireConfigAliases);\n\n }, reject);\n\n\n });\n };\n\n /**\n * Evaluate if the given object is a proper portable element provider\n * @param {Object} provider\n * @returns {Boolean}\n */\n var isPortableElementProvider = function isPortableElementProvider(provider){\n return (provider && _.isFunction(provider.load));\n };\n\n return function portableElementRegistry(methods){\n\n var _loaded = false;\n var __providers = {};\n\n /**\n * The portable element registry instance\n * @typedef {portableElementRegistry}\n */\n return eventifier(_.defaults(methods || {}, {\n _registry : {},\n\n /**\n * Get a register portable element\n * @param {String} typeIdentifier\n * @param {String} version\n * @returns {Object}\n */\n get : function get(typeIdentifier, version){\n\n if(this._registry[typeIdentifier]){\n //check version\n if(version){\n return _.find(this._registry[typeIdentifier], {version : version});\n }else{\n //latest\n return _.last(this._registry[typeIdentifier]);\n }\n }\n },\n\n /**\n * Register a portable element provider\n * @param moduleName\n * @param {String|Object }provider - the portable provider object or module name\n * @returns {portableElementRegistry}\n */\n registerProvider : function registerProvider(moduleName, provider){\n __providers[moduleName] = isPortableElementProvider(provider) ? provider : null;\n _loaded = false;\n return this;\n },\n\n /**\n * Clear all previously registered providers\n * @returns {portableElementRegistry}\n */\n resetProviders : function resetProviders(){\n __providers = {};\n _loaded = false;\n return this;\n },\n\n /**\n * Load the providers\n * @param {Object} [options]\n * @param {Boolean} [options.reload] - force to reload the registered providers\n * @returns {Promise}\n */\n loadProviders : function loadProviders(options){\n var self = this;\n var loadPromise;\n\n if(_loaded && !options.reload){\n loadPromise = Promise.resolve([]);\n } else {\n loadPromise = new Promise(function(resolve, reject) {\n var providerLoadingStack = [];\n _.forIn(__providers, function(provider, id){\n if(provider === null){\n providerLoadingStack.push(id);\n }\n });\n _requirejs(providerLoadingStack, function(){\n _.each([].slice.call(arguments), function(provider){\n if(isPortableElementProvider(provider)){\n __providers[providerLoadingStack.shift()] = provider;\n }\n });\n resolve(__providers);\n _loaded = true;\n self.trigger('providersloaded', __providers);\n }, reject);\n });\n }\n\n return loadPromise;\n },\n\n /**\n * Get all versions of all portable elements registered\n * @returns {Object} - all portable elements and their versions\n */\n getAllVersions : function getAllVersions(){\n var all = {};\n _.forIn(this._registry, function (versions, id){\n all[id] = _.map(versions, 'version');\n });\n return all;\n },\n\n /**\n * Get the runtime for a given portable element\n * @param {String} typeIdentifier\n * @param {String} [version] - if the version is provided, the method will try to find that version\n * @returns {Object} the runtime model\n */\n getRuntime : function getRuntime(typeIdentifier, version){\n var portableElement = this.get(typeIdentifier, version);\n if(portableElement){\n return _.assign(portableElement.runtime, {\n id : portableElement.typeIdentifier,\n label : portableElement.label,\n baseUrl : portableElement.baseUrl,\n model : portableElement.model\n });\n }else{\n this.trigger('error', {\n message : 'no portable element runtime found',\n typeIdentifier : typeIdentifier,\n version : version\n });\n }\n },\n\n /**\n * Get the creator model for a given portable element\n * @param {String} typeIdentifier\n * @param {String} [version] - if the version is provided, the method will try to find that version\n * @returns {Object} the creator model\n */\n getCreator : function getCreator(typeIdentifier, version){\n var portableElement = this.get(typeIdentifier, version);\n if(portableElement && portableElement.creator){\n return _.assign(portableElement.creator, {\n id : portableElement.typeIdentifier,\n label : portableElement.label,\n baseUrl : portableElement.baseUrl,\n response : portableElement.response,\n model : portableElement.model,\n xmlns : portableElement.xmlns\n });\n }else{\n this.trigger('error', {\n message : 'no portable element runtime found',\n typeIdentifier : typeIdentifier,\n version : version\n });\n }\n },\n\n /**\n * Returned all enabled created from the registry\n * @returns {Object} the collection of creators\n */\n getLatestCreators : function getLatestCreators(){\n var all = {};\n _.forIn(this._registry, function (versions, id){\n var lastVersion = _.last(versions);\n\n //check if the portable element is creatable:\n if(lastVersion.creator && lastVersion.creator.hook && lastVersion.enabled){\n all[id] = lastVersion;\n }\n });\n return all;\n },\n\n /**\n * Get the baseUrl for a given portable element\n * @param {String} typeIdentifier\n * @param {String} [version] - if the version is provided, the method will try to find that version\n * @returns {String} the base url\n */\n getBaseUrl : function getBaseUrl(typeIdentifier, version){\n var runtime = this.get(typeIdentifier, version);\n if(runtime){\n return runtime.baseUrl;\n }\n return '';\n },\n\n /**\n * Load the runtimes from registered portable element provider(s)\n *\n * @param {Object} [options]\n * @param {Array} [options.include] - the exact list of portable element typeIdentifier that should be loaded\n * @param {Boolean} [options.reload] - tells if all interactions should be reloaded\n * @returns {Promise}\n */\n loadRuntimes : function loadRuntimes(options){\n var self = this;\n var loadPromise;\n\n options = _.defaults(options||{}, _defaultLoadingOptions);\n\n loadPromise = self.loadProviders(options).then(function(providers){\n\n var loadStack = [];\n\n _.forEach(providers, function (provider){\n if(provider){//check that the provider is loaded\n loadStack.push(provider.load());\n }\n });\n\n //performs the loadings in parallel\n return Promise.all(loadStack).then(function (results){//TODO could remove one level of promise\n\n var configLoadingStack = [];\n\n //update registry\n self._registry = _.reduce(results, function (acc, _pcis){\n return _.merge(acc, _pcis);\n }, self._registry || {});//incremental loading\n\n //pre-configuring the baseUrl of the portable element's source\n _.forIn(self._registry, function (versions, typeIdentifier){\n if(_.isArray(options.include) && _.indexOf(options.include, typeIdentifier) < 0){\n return true;\n }\n configLoadingStack.push(loadModuleConfig(self.get(typeIdentifier)));\n });\n\n return Promise.all(configLoadingStack).then(function(moduleConfigs){\n var requireConfigAliases = _.reduce(moduleConfigs, function(acc, paths){\n return _.merge(acc, paths);\n }, {});\n\n //save the required libs name => path to global require alias\n //TODO in future planned user story : change this to a local require context to solve conflicts in third party module naming\n _requirejs.config({paths : requireConfigAliases});\n });\n });\n\n });\n\n\n loadPromise\n .then(function() {\n self.trigger('runtimesloaded');\n })\n .catch(function(err) {\n self.trigger('error', err);\n });\n\n return loadPromise;\n },\n\n /**\n * Load the creators from registered portable element provider(s)\n *\n * @param {Object} [options]\n * @param {Array} [options.include] - the exact list of portable element typeIdentifier that should be loaded\n * @param {Boolean} [options.reload] - tells if all interactions should be reloaded\n * @returns {Promise}\n */\n loadCreators : function loadCreators(options){\n var loadPromise;\n var self = this;\n\n options = _.defaults(options||{}, _defaultLoadingOptions);\n\n loadPromise = self.loadRuntimes(options).then(function(){\n var requiredCreatorHooks = [];\n\n _.forIn(self._registry, function (versions, typeIdentifier){\n var portableElementModel = self.get(typeIdentifier);//currently use the latest version only\n if(portableElementModel.creator && portableElementModel.creator.hook){\n if(portableElementModel.enabled){\n if(_.isArray(options.include) && _.indexOf(options.include, typeIdentifier) < 0){\n return true;\n }\n }else{\n if(!_.isArray(options.include) || _.indexOf(options.include, typeIdentifier) < 0){\n return true;\n }\n }\n requiredCreatorHooks.push(portableElementModel.creator.hook.replace(/\\.js$/, ''));\n }\n });\n\n if(requiredCreatorHooks.length){\n return new Promise(function(resolve, reject){\n //@todo support caching?\n _requirejs(requiredCreatorHooks, function (){\n var creators = {};\n _.each(arguments, function (creatorHook){\n var id = creatorHook.getTypeIdentifier();\n var portableElementModel = self.get(id);\n var i = _.findIndex(self._registry[id], {version : portableElementModel.version});\n if(i < 0){\n self.trigger('error', 'no creator found for id/version ' + id + '/' + portableElementModel.version);\n }else{\n self._registry[id][i].creator.module = creatorHook;\n creators[id] = creatorHook;\n }\n });\n resolve(creators);\n }, reject);\n });\n }else{\n return Promise.resolve({});\n }\n\n });\n\n loadPromise\n .then(function(creators) {\n self.trigger('creatorsloaded', creators);\n return creators;\n })\n .catch(function(err) {\n self.trigger('error', err);\n });\n\n return loadPromise;\n },\n\n /**\n * enable a portable element\n * @param {String} typeIdentifier\n * @param {String} [version] - if the version is provided, the method will try to find that version\n * @returns {portableElementRegistry}\n */\n enable: function enable(typeIdentifier, version){\n var portableElement = this.get(typeIdentifier, version);\n if(portableElement){\n portableElement.enabled = true;\n }\n return this;\n },\n\n /**\n * disable a portable element\n * @param {String} typeIdentifier\n * @param {String} [version] - if the version is provided, the method will try to find that version\n * @returns {portableElementRegistry}\n */\n disable: function disable(typeIdentifier, version){\n var portableElement = this.get(typeIdentifier, version);\n if(portableElement){\n portableElement.enabled = false;\n }\n return this;\n },\n\n /**\n * check is a portable element is enabled\n * @param {String} typeIdentifier\n * @param {String} [version] - if the version is provided, the method will try to find that version\n * @returns {portableElementRegistry}\n */\n isEnabled: function isEnabled(typeIdentifier, version){\n var portableElement = this.get(typeIdentifier, version);\n return (portableElement && portableElement.enabled === true);\n }\n }));\n };\n});\n","/**\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2015-2022 (original work) Open Assessment Technologies SA ;\n */\n/**\n * Utility to retrieve and manipualte QTI Elements\n */\ndefine('taoQtiItem/qtiCreator/helper/qtiElements',['jquery', 'lodash', 'i18n', 'services/features'], function ($, _, __, featuresService) {\n 'use strict';\n\n const QtiElements = {\n classes: {\n //abstract classes:\n itemBody: { parents: ['bodyElement'], contains: ['block'], abstract: true },\n atomicBlock: {\n parents: ['blockStatic', 'bodyElement', 'flowStatic'],\n contains: ['inline'],\n abstract: true\n },\n atomicInline: {\n parents: ['bodyElement', 'flowStatic', 'inlineStatic'],\n contains: ['inline'],\n abstract: true\n },\n simpleBlock: { parents: ['blockStatic', 'bodyElement', 'flowStatic'], contains: ['block'], abstract: true },\n simpleInline: {\n parents: ['bodyElement', 'flowStatic', 'inlineStatic'],\n contains: ['inline'],\n abstract: true\n },\n flowStatic: { parents: ['flow'], abstract: true },\n blockStatic: { parents: ['block'], abstract: true },\n inlineStatic: { parents: ['inline'], abstract: true },\n flow: { parents: ['objectFlow'], abstract: true },\n tableCell: { parents: ['bodyElement'], contains: ['flow'], abstract: true },\n //html-derived qti elements:\n caption: { parents: ['bodyElement'], contains: ['inline'], xhtml: true },\n col: { parents: ['bodyElement'], xhtml: true },\n colgroup: { parents: ['bodyElement'], contains: ['col'], xhtml: true },\n div: { parents: ['blockStatic', 'bodyElement', 'flowStatic'], contains: ['flow'], xhtml: true },\n dl: { parents: ['blockStatic', 'bodyElement', 'flowStatic'], contains: ['dlElement'], xhtml: true },\n dt: { parents: ['dlElement'], contains: ['inline'], xhtml: true },\n dd: { parents: ['dlElement'], contains: ['flow'], xhtml: true },\n hr: { parents: ['blockStatic', 'bodyElement', 'flowStatic'], xhtml: true },\n math: { parents: ['blockStatic', 'flowStatic', 'inlineStatic'], xhtml: true },\n li: { parents: ['bodyElement'], contains: ['flow'], xhtml: true },\n ol: { parents: ['blockStatic', 'bodyElement', 'flowStatic'], contains: ['li'], xhtml: true },\n ul: { parents: ['blockStatic', 'bodyElement', 'flowStatic'], contains: ['li'], xhtml: true },\n object: { parents: ['bodyElement', 'flowStatic', 'inlineStatic'], contains: ['objectFlow'], xhtml: true },\n param: { parents: ['objectFlow'], xhtml: true },\n table: {\n parents: ['blockStatic', 'bodyElement', 'flowStatic'],\n contains: ['caption', 'col', 'colgroup', 'thead', 'tfoot', 'tbody'],\n xhtml: true\n },\n tbody: { parents: ['bodyElement'], contains: ['tr'], xhtml: true },\n tfoot: { parents: ['bodyElement'], contains: ['tr'], xhtml: true },\n thead: { parents: ['bodyElement'], contains: ['tr'], xhtml: true },\n td: { parents: ['tableCell'], xhtml: true },\n th: { parents: ['tableCell'], xhtml: true },\n tr: { parents: ['bodyElement'], contains: ['tableCell'], xhtml: true },\n a: { parents: ['simpleInline'], xhtml: true },\n abbr: { parents: ['simpleInline'], xhtml: true },\n acronym: { parents: ['simpleInline'], xhtml: true },\n b: { parents: ['simpleInline'], xhtml: true },\n big: { parents: ['simpleInline'], xhtml: true },\n cite: { parents: ['simpleInline'], xhtml: true },\n code: { parents: ['simpleInline'], xhtml: true },\n dfn: { parents: ['simpleInline'], xhtml: true },\n em: { parents: ['simpleInline'], xhtml: true },\n i: { parents: ['simpleInline'], xhtml: true },\n kbd: { parents: ['simpleInline'], xhtml: true },\n q: { parents: ['simpleInline'], xhtml: true },\n samp: { parents: ['simpleInline'], xhtml: true },\n small: { parents: ['simpleInline'], xhtml: true },\n span: { parents: ['simpleInline'], xhtml: true },\n strong: { parents: ['simpleInline'], xhtml: true },\n sub: { parents: ['simpleInline'], xhtml: true },\n sup: { parents: ['simpleInline'], xhtml: true },\n tt: { parents: ['simpleInline'], xhtml: true },\n var: { parents: ['simpleInline'], xhtml: true },\n blockquote: { parents: ['simpleBlock'], xhtml: true },\n address: { parents: ['atomicBlock'], xhtml: true },\n h1: { parents: ['atomicBlock'], xhtml: true },\n h2: { parents: ['atomicBlock'], xhtml: true },\n h3: { parents: ['atomicBlock'], xhtml: true },\n h4: { parents: ['atomicBlock'], xhtml: true },\n h5: { parents: ['atomicBlock'], xhtml: true },\n h6: { parents: ['atomicBlock'], xhtml: true },\n p: { parents: ['atomicBlock'], xhtml: true },\n pre: { parents: ['atomicBlock'], xhtml: true },\n img: { parents: ['atomicInline'], xhtml: true, attributes: ['src', 'alt', 'longdesc', 'height', 'width'] },\n br: { parents: ['atomicInline'], xhtml: true },\n //qti elements:\n infoControl: { parents: ['blockStatic', 'bodyElement', 'flowStatic'], qti: true },\n textRun: { parents: ['inlineStatic', 'flowstatic'], qti: true },\n feedbackInline: { parents: ['simpleInline', 'feedbackElement'], qti: true },\n feedbackBlock: { parents: ['simpleBlock'], qti: true },\n rubricBlock: { parents: ['simpleBlock'], qti: true }, //strange qti 2.1 exception, marked as simpleBlock instead of\n blockInteraction: { parents: ['block', 'flow', 'interaction'], qti: true },\n inlineInteraction: { parents: ['inline', 'flow', 'interaction'], qti: true },\n gap: { parents: ['inlineStatic'], qti: true },\n hottext: { parents: ['flowstatic', 'inlineStatic'], contains: ['inlineStatic'], qti: true },\n printedVariable: { parents: ['bodyElement', 'flowStatic', 'inlineStatic', 'textOrVariable'], qti: true },\n prompt: { parents: ['bodyElement'], contains: ['inlineStatic'], qti: true },\n templateElement: { parents: ['bodyElement'], qti: true },\n templateBlock: {\n parents: ['blockStatic', 'flowStatic', 'templateElement'],\n contains: ['blockStatic'],\n qti: true\n },\n templateInline: {\n parents: ['inlineStatic', 'flowStatic', 'templateElement'],\n contains: ['inlineStatic'],\n qti: true\n },\n choiceInteraction: { parents: ['blockInteraction'], qti: true },\n associateInteraction: { parents: ['blockInteraction'], qti: true },\n orderInteraction: { parents: ['blockInteraction'], qti: true },\n matchInteraction: { parents: ['blockInteraction'], qti: true },\n hottextInteraction: { parents: ['blockInteraction'], qti: true },\n gapMatchInteraction: { parents: ['blockInteraction'], qti: true },\n mediaInteraction: { parents: ['blockInteraction'], qti: true },\n sliderInteraction: { parents: ['blockInteraction'], qti: true },\n uploadInteraction: { parents: ['blockInteraction'], qti: true },\n drawingInteraction: { parents: ['blockInteraction'], qti: true },\n graphicInteraction: { parents: ['blockInteraction'], qti: true },\n hotspotInteraction: { parents: ['graphicInteraction'], qti: true },\n graphicAssociateInteraction: { parents: ['graphicInteraction'], qti: true },\n graphicOrderInteraction: { parents: ['graphicInteraction'], qti: true },\n graphicGapMatchInteraction: { parents: ['graphicInteraction'], qti: true },\n selectPointInteraction: { parents: ['graphicInteraction'], qti: true },\n textEntryInteraction: { parents: ['stringInteraction', 'inlineInteraction'], qti: true },\n extendedTextInteraction: { parents: ['stringInteraction', 'blockInteraction'], qti: true },\n inlineChoiceInteraction: { parents: ['inlineInteraction'], qti: true },\n endAttemptInteraction: { parents: ['inlineInteraction'], qti: true },\n customInteraction: { parents: ['block', 'flow', 'interaction'], qti: true },\n _container: { parents: ['block'], qti: true } //a pseudo class introduced in TAO\n },\n\n cache: { containable: {}, children: {}, parents: {} },\n\n getAllowedContainersElements(qtiClass, $container) {\n const classes = QtiElements.getAllowedContainers(qtiClass);\n let jqSelector = '';\n for (let i in classes) {\n if (!classes[i].qti) {\n //html element:\n jqSelector += `${classes[i]}, `;\n }\n }\n\n if (jqSelector) {\n jqSelector = jqSelector.substring(0, jqSelector.length - 2);\n }\n\n return $(jqSelector, $container ? $container : $(document)).filter(':not([data-qti-type])');\n },\n\n getAllowedContainers(qtiClass) {\n let ret;\n if (QtiElements.cache.containable[qtiClass]) {\n ret = QtiElements.cache.containable[qtiClass];\n } else {\n ret = [];\n const parents = QtiElements.getParentClasses(qtiClass, true);\n for (let aClass in QtiElements.classes) {\n const model = QtiElements.classes[aClass];\n if (model.contains) {\n const intersect = _.intersection(model.contains, parents);\n if (intersect.length) {\n if (!model.abstract) {\n ret.push(aClass);\n }\n ret = _.union(ret, QtiElements.getChildClasses(aClass, true));\n }\n }\n }\n QtiElements.cache.containable[qtiClass] = ret;\n }\n\n return ret;\n },\n\n getAllowedContents(qtiClass, recursive, checked) {\n let ret = [];\n checked = checked || {};\n\n const model = QtiElements.classes[qtiClass];\n if (model && model.contains) {\n for (let i in model.contains) {\n const contain = model.contains[i];\n if (!checked[contain]) {\n checked[contain] = true;\n\n //qtiClass can contain everything defined as its contents\n ret.push(contain);\n\n //qtiClass can also contain subclass of its contents\n const children = QtiElements.getChildClasses(contain, true);\n for (let j in children) {\n const child = children[j];\n if (!checked[child]) {\n checked[child] = true;\n\n ret.push(child);\n\n //adding children allowed contents depends on the option \"recursive\"\n if (recursive) {\n ret = _.union(ret, QtiElements.getAllowedContents(child, true, checked));\n }\n }\n }\n\n //adding allowed contents of qtiClass' allowed contents depends on the option \"recursive\"\n if (recursive) {\n ret = _.union(ret, QtiElements.getAllowedContents(contain, true, checked));\n }\n }\n }\n }\n\n //qtiClass can contain all allowed contents of its parents:\n const parents = QtiElements.getParentClasses(qtiClass, true);\n for (let i in parents) {\n ret = _.union(ret, QtiElements.getAllowedContents(parents[i], recursive, checked));\n }\n\n return _.uniq(ret, false);\n },\n\n isAllowedClass(qtiContainerClass, qtiContentClass) {\n const allowedClasses = QtiElements.getAllowedContents(qtiContainerClass);\n return _.indexOf(allowedClasses, qtiContentClass) >= 0;\n },\n\n getParentClasses(qtiClass, recursive) {\n let ret;\n if (recursive && QtiElements.cache.parents[qtiClass]) {\n ret = QtiElements.cache.parents[qtiClass];\n } else {\n ret = [];\n if (QtiElements.classes[qtiClass]) {\n ret = QtiElements.classes[qtiClass].parents;\n if (recursive) {\n for (let i in ret) {\n ret = _.union(ret, QtiElements.getParentClasses(ret[i], recursive));\n }\n ret = _.uniq(ret, false);\n }\n }\n QtiElements.cache.parents[qtiClass] = ret;\n }\n\n return ret;\n },\n\n getChildClasses(qtiClass, recursive, type) {\n let ret;\n const cacheType = type ? type : 'all';\n if (recursive && QtiElements.cache.children[qtiClass] && QtiElements.cache.children[qtiClass][cacheType]) {\n ret = QtiElements.cache.children[qtiClass][cacheType];\n } else {\n ret = [];\n for (let aClass in QtiElements.classes) {\n const model = QtiElements.classes[aClass];\n if (_.indexOf(model.parents, qtiClass) >= 0) {\n if (type) {\n if (model[type]) {\n ret.push(aClass);\n }\n } else {\n ret.push(aClass);\n }\n if (recursive) {\n ret = _.union(ret, QtiElements.getChildClasses(aClass, recursive, type));\n }\n }\n }\n if (!QtiElements.cache.children[qtiClass]) {\n QtiElements.cache.children[qtiClass] = {};\n }\n QtiElements.cache.children[qtiClass][cacheType] = ret;\n }\n\n return ret;\n },\n\n isBlock(qtiClass) {\n return QtiElements.is(qtiClass, 'block');\n },\n\n isInline(qtiClass) {\n return QtiElements.is(qtiClass, 'inline');\n },\n\n is(qtiClass, topClass) {\n if (qtiClass === topClass) {\n return true;\n } else {\n const parents = QtiElements.getParentClasses(qtiClass, true);\n return _.indexOf(parents, topClass) >= 0;\n }\n },\n\n /**\n * Check wether an element is visible, using the feature viibility service\n * @param {string} qtiClass - see the list of available classes\n * @returns {boolean} true by default and false only if the element is explicitely registered as hidden\n */\n isVisible(qtiClass) {\n if (this.is(qtiClass, 'customInteraction')) {\n return featuresService.isVisible(`taoQtiItem/creator/customInteraction/${qtiClass.replace(/Interaction$/, '').replace(/^customInteraction\\./, '')}`);\n }\n if (this.is(qtiClass, 'interaction')) {\n return featuresService.isVisible(`taoQtiItem/creator/interaction/${qtiClass.replace(/Interaction$/, '')}`);\n }\n return true;\n },\n\n /**\n * Get the list of available elements for the authoring side\n * The list of those element is statically defined, but we filter out elements that should be visible\n * @returns {Object} the available elements\n */\n getAvailableAuthoringElements() {\n const tagTitles = {\n commonInteractions: __('Common Interactions'),\n inlineInteractions: __('Inline Interactions'),\n graphicInteractions: __('Graphic Interactions')\n };\n\n const authoringElements = {\n choiceInteraction: {\n label: __('Choice Interaction'),\n description: __(\n 'Select a single (radio buttons) or multiple (check boxes) responses among a set of choices.'\n ),\n icon: 'icon-choice',\n short: __('Choice'),\n qtiClass: 'choiceInteraction',\n tags: [tagTitles.commonInteractions, 'mcq'],\n group: 'common-interactions'\n },\n orderInteraction: {\n label: __('Order Interaction'),\n icon: 'icon-order',\n description: __('Arrange a list of choices in the correct order.'),\n short: __('Order'),\n qtiClass: 'orderInteraction',\n tags: [tagTitles.commonInteractions, 'ordering'],\n group: 'common-interactions'\n },\n associateInteraction: {\n label: __('Associate Interaction'),\n icon: 'icon-associate',\n description: __('Create pair(s) from a series of choices.'),\n short: __('Associate'),\n qtiClass: 'associateInteraction',\n tags: [tagTitles.commonInteractions, 'association'],\n group: 'common-interactions'\n },\n matchInteraction: {\n label: __('Match Interaction'),\n icon: 'icon-match',\n description: __(\n 'Create association(s) between two sets of choices displayed in a table (row and column).'\n ),\n short: __('Match'),\n qtiClass: 'matchInteraction',\n tags: [tagTitles.commonInteractions, 'association'],\n group: 'common-interactions'\n },\n hottextInteraction: {\n label: __('Hottext Interaction'),\n icon: 'icon-hottext',\n description: __('Select one or more text parts (hottext) within a text.'),\n short: __('Hottext'),\n qtiClass: 'hottextInteraction',\n tags: [tagTitles.commonInteractions, 'text'],\n group: 'common-interactions'\n },\n gapMatchInteraction: {\n label: __('Gap Match Interaction'),\n icon: 'icon-gap-match',\n description: __(' Fill in the gaps in a text from a set of choices.'),\n short: __('Gap Match'),\n qtiClass: 'gapMatchInteraction',\n tags: [tagTitles.commonInteractions, 'text', 'association'],\n group: 'common-interactions'\n },\n sliderInteraction: {\n label: __('Slider Interaction'),\n icon: 'icon-slider',\n description: __('Select a value within a numerical range.'),\n short: __('Slider'),\n qtiClass: 'sliderInteraction',\n tags: [tagTitles.commonInteractions, 'special'],\n group: 'common-interactions'\n },\n extendedTextInteraction: {\n label: __('Extended Text Interaction'),\n icon: 'icon-extended-text',\n description: __(\n 'Collect open-ended information in one or more text area(s) (strings or numeric values).'\n ),\n short: __('Extended Text'),\n qtiClass: 'extendedTextInteraction',\n tags: [tagTitles.commonInteractions, 'text'],\n group: 'common-interactions'\n },\n uploadInteraction: {\n label: __('File Upload Interaction'),\n icon: 'icon-upload',\n description: __('Upload a file (e.g. document, picture...) as a response.'),\n short: __('File Upload'),\n qtiClass: 'uploadInteraction',\n tags: [tagTitles.commonInteractions, 'special'],\n group: 'common-interactions'\n },\n mediaInteraction: {\n label: __('Media Interaction'),\n icon: 'icon-media',\n description: __(\n 'Control the playing parameters (auto-start, loop) of a video or audio file and report the number of time it has been played.'\n ),\n short: __('Media'),\n qtiClass: 'mediaInteraction',\n tags: [tagTitles.commonInteractions, 'media'],\n group: 'common-interactions'\n },\n _container: {\n label: __('Text Block'),\n icon: 'icon-font',\n description: __(\n 'Block contains the content (stimulus) of the item such as text or image. It is also required for Inline Interactions.'\n ),\n short: __('Block'),\n qtiClass: '_container',\n tags: [tagTitles.inlineInteractions, 'text'],\n group: 'inline-interactions'\n },\n inlineChoiceInteraction: {\n label: __('Inline Choice Interaction'),\n icon: 'icon-inline-choice',\n description: __('Select a choice from a drop-down list.'),\n short: __('Inline Choice'),\n qtiClass: 'inlineChoiceInteraction',\n tags: [tagTitles.inlineInteractions, 'inline-interactions', 'mcq'],\n group: 'inline-interactions'\n },\n textEntryInteraction: {\n label: __('Text Entry Interaction'),\n icon: 'icon-text-entry',\n description: __(\n 'Collect open-ended information in a short text input (strings or numeric values).'\n ),\n short: __('Text Entry'),\n qtiClass: 'textEntryInteraction',\n tags: [tagTitles.inlineInteractions, 'inline-interactions', 'text'],\n group: 'inline-interactions'\n },\n endAttemptInteraction: {\n label: __('End Attempt Interaction'),\n icon: 'icon-end-attempt',\n description: __('Trigger the end of the item attempt.'),\n short: __('End Attempt'),\n qtiClass: 'endAttemptInteraction',\n tags: [tagTitles.inlineInteractions, 'inline-interactions', 'button', 'submit'],\n group: 'inline-interactions'\n },\n hotspotInteraction: {\n label: __('Hotspot Interaction'),\n icon: 'icon-hotspot',\n description: __('Select one or more areas (hotspots) displayed on an picture.'),\n short: __('Hotspot'),\n qtiClass: 'hotspotInteraction',\n tags: [tagTitles.graphicInteractions, 'mcq'],\n group: 'graphic-interactions'\n },\n graphicOrderInteraction: {\n label: __('Graphic Order Interaction'),\n icon: 'icon-graphic-order',\n description: __('Order the areas (hotspots) displayed on a picture.'),\n short: __('Order'),\n qtiClass: 'graphicOrderInteraction',\n tags: [tagTitles.graphicInteractions, 'ordering'],\n group: 'graphic-interactions'\n },\n graphicAssociateInteraction: {\n label: __('Graphic Associate Interaction'),\n icon: 'icon-graphic-associate',\n description: __('Create association(s) between areas (hotspots) displayed on a picture.'),\n short: __('Associate'),\n qtiClass: 'graphicAssociateInteraction',\n tags: [tagTitles.graphicInteractions, 'association'],\n group: 'graphic-interactions'\n },\n graphicGapMatchInteraction: {\n label: __('Graphic Gap Match Interaction'),\n icon: 'icon-graphic-gap',\n description: __('Fill in the gaps on a picture with a set of image choices.'),\n short: __('Gap Match'),\n qtiClass: 'graphicGapMatchInteraction',\n tags: [tagTitles.graphicInteractions, 'association'],\n group: 'graphic-interactions'\n },\n selectPointInteraction: {\n label: __('Select Point Interaction'),\n icon: 'icon-select-point',\n description: __('Position one or more points on a picture (response areas are not displayed).'),\n short: __('Select Point'),\n qtiClass: 'selectPointInteraction',\n tags: [tagTitles.graphicInteractions],\n group: 'graphic-interactions'\n }\n };\n\n //filter out hidden elements\n const availableElements = {};\n for (const [elementId, element] of Object.entries(authoringElements)) {\n if (this.isVisible(elementId)) {\n availableElements[elementId] = element;\n }\n }\n return availableElements;\n }\n };\n\n return QtiElements;\n});\n\n","/*\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2016-2022 (original work) Open Assessment Technologies SA;\n *\n */\ndefine('taoQtiItem/portableElementRegistry/factory/ciRegistry',[\n 'lodash',\n 'i18n',\n 'taoQtiItem/portableElementRegistry/factory/factory',\n 'taoQtiItem/qtiCreator/helper/qtiElements'\n], function (_, __, portableElementRegistry, qtiElements) {\n 'use strict';\n\n /**\n * Create a ney interaction registry instance\n * interaction registry need to register newly loaded creator hooks in the list of available qti authoring elements\n *\n * @returns {Object} registry instance\n */\n return function customInteractionRegistry() {\n return portableElementRegistry({\n /**\n * Get the authoring information for a given custom interaction\n * @param {string} typeIdentifier - the interaction type identifier\n * @param {Object} [options]\n * @param {string|number} [options.version] - the interaction version\n * @param {boolean} [options.enabledOnly] - to only get interaction enabled && visible\n * @returns {Object} the authoring info\n */\n getAuthoringData(typeIdentifier, options = {}) {\n options = _.defaults(options || {}, { version: 0, enabledOnly: false });\n const pciModel = this.get(typeIdentifier, options.version);\n const qtiClass = `customInteraction.${pciModel.typeIdentifier}`;\n if (\n pciModel &&\n pciModel.creator &&\n pciModel.creator.hook &&\n pciModel.creator.icon &&\n ((pciModel.enabled && qtiElements.isVisible(qtiClass)) || !options.enabledOnly)\n ) {\n return {\n label: pciModel.label, //currently no translation available\n icon: pciModel.creator.icon.replace(new RegExp(`^${typeIdentifier}/`), pciModel.baseUrl),\n short: pciModel.short,\n description: pciModel.description,\n qtiClass, //custom interaction is block type\n tags: _.union([__('Custom Interactions')], pciModel.tags),\n group: 'custom-interactions'\n };\n }\n }\n }).on('creatorsloaded', function () {\n const creators = this.getLatestCreators();\n _.forEach(creators, function (creator, typeIdentifier) {\n qtiElements.classes[`customInteraction.${typeIdentifier}`] = {\n parents: ['customInteraction'],\n qti: true\n };\n });\n });\n };\n});\n\n","/*\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2016 (original work) Open Assessment Technologies SA;\n *\n */\ndefine('taoQtiItem/portableElementRegistry/ciRegistry',['lodash', 'taoQtiItem/portableElementRegistry/factory/ciRegistry', 'module'], function (_, ciRegistry, module){\n 'use strict';\n\n //create a preregistered singleton of ciRegistry\n var registry = ciRegistry();\n var providers = [];\n var config = module.config();\n\n if(config && config.providers){\n providers = config.providers;\n }\n\n _.each(providers, function(provider){\n if(provider.name && provider.module){\n registry.registerProvider(provider.module);\n }\n });\n\n return registry;\n});\n","/*\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2016 (original work) Open Assessment Technologies SA;\n *\n */\ndefine('taoQtiItem/portableElementRegistry/factory/icRegistry',[\n 'lodash',\n 'taoQtiItem/portableElementRegistry/factory/factory'\n], function (_, portableElementRegistry){\n 'use strict';\n\n /**\n * Info control registry has currently no additonal fonctionalities than the basic portable element registry\n *\n * @returns {Object} registry instance\n */\n return function infoControlRegistry(){\n return portableElementRegistry();\n }\n\n});\n","/*\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2016 (original work) Open Assessment Technologies SA;\n *\n */\ndefine('taoQtiItem/portableElementRegistry/icRegistry',['lodash', 'taoQtiItem/portableElementRegistry/factory/icRegistry', 'module'], function (_, icRegistry, module){\n 'use strict';\n\n //create a preregistered singleton of icRegistry\n var registry = icRegistry();\n var providers = [];\n var config = module.config();\n\n if(config && config.providers){\n providers = config.providers;\n }\n\n _.each(providers, function(provider){\n if(provider.name && provider.module){\n registry.registerProvider(provider.module);\n }\n });\n\n return registry;\n});\n","/**\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2016 (original work) Open Assessment Technologies SA;\n */\n\ndefine('taoQtiItem/portableElementRegistry/assetManager/portableAssetStrategy',[\n 'taoQtiItem/portableElementRegistry/ciRegistry',\n 'taoQtiItem/portableElementRegistry/icRegistry'\n], function (ciRegistry, icRegistry) {\n 'use strict';\n\n function getBaseUrlByIdentifier(typeIdentifier) {\n if (ciRegistry.get(typeIdentifier)) {\n return ciRegistry.getBaseUrl(typeIdentifier);\n }\n if (icRegistry.get(typeIdentifier)) {\n return icRegistry.getBaseUrl(typeIdentifier);\n }\n return typeIdentifier;\n }\n\n //strategy to resolve portable info control and portable interactions paths.\n //It should never be reached in the stack the usual way and should be called only using resolveBy.\n return {\n name: 'portableElementLocation',\n handle: function handlePortableElementLocation(url) {\n\n if (url.file === url.path) {\n return getBaseUrlByIdentifier(url.file);\n } else if (url.source === url.relative) {\n return url.relative.replace(/^(\\.\\/)?([a-z_0-9]+)\\/(.*)/i, function (fullmatch, $1, typeIdentifier, relPath) {\n var runtimeLocation = getBaseUrlByIdentifier(typeIdentifier);\n if (runtimeLocation) {\n return runtimeLocation + '/' + relPath;\n }\n return fullmatch;\n });\n }\n }\n };\n});\n","define('taoQtiItem/qtiCommonRenderer/renderers/config',['lodash', 'context', 'ui/themes', 'taoItems/assets/manager', 'taoItems/assets/strategies', 'module', 'taoQtiItem/portableElementRegistry/assetManager/portableAssetStrategy'], function (_, context, themes, assetManagerFactory, assetStrategies, module, portableAssetStrategy) { 'use strict';\n\n _ = _ && Object.prototype.hasOwnProperty.call(_, 'default') ? _['default'] : _;\n context = context && Object.prototype.hasOwnProperty.call(context, 'default') ? context['default'] : context;\n themes = themes && Object.prototype.hasOwnProperty.call(themes, 'default') ? themes['default'] : themes;\n assetManagerFactory = assetManagerFactory && Object.prototype.hasOwnProperty.call(assetManagerFactory, 'default') ? assetManagerFactory['default'] : assetManagerFactory;\n assetStrategies = assetStrategies && Object.prototype.hasOwnProperty.call(assetStrategies, 'default') ? assetStrategies['default'] : assetStrategies;\n module = module && Object.prototype.hasOwnProperty.call(module, 'default') ? module['default'] : module;\n portableAssetStrategy = portableAssetStrategy && Object.prototype.hasOwnProperty.call(portableAssetStrategy, 'default') ? portableAssetStrategy['default'] : portableAssetStrategy;\n\n /**\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2014 (original work) Open Assessment Technologies SA;\n */\n\n var itemThemes = themes.get('items');\n var moduleConfig = module.config();\n\n //Create asset manager stack\n var assetManager = assetManagerFactory(\n [\n {\n name: 'theme',\n handle: function handleTheme(url) {\n if (\n itemThemes &&\n url.path &&\n (url.path === itemThemes.base || _.contains(_.pluck(itemThemes.available, 'path'), url.path))\n ) {\n return context.root_url + url.toString();\n }\n }\n },\n assetStrategies.taomedia,\n assetStrategies.external,\n assetStrategies.base64,\n assetStrategies.itemCssNoCache,\n assetStrategies.baseUrl,\n portableAssetStrategy\n ],\n { baseUrl: '' }\n ); //baseUrl is not predefined in the config, but should be set upon renderer instantiating\n\n //renderers locations\n var locations = {\n assessmentItem: 'taoQtiItem/qtiCommonRenderer/renderers/Item',\n _container: 'taoQtiItem/qtiCommonRenderer/renderers/Container',\n _simpleFeedbackRule: false,\n _tooltip: 'taoQtiItem/qtiCommonRenderer/renderers/Tooltip',\n stylesheet: 'taoQtiItem/qtiCommonRenderer/renderers/Stylesheet',\n outcomeDeclaration: false,\n responseDeclaration: false,\n responseProcessing: false,\n figure: 'taoQtiItem/qtiCommonRenderer/renderers/Figure',\n img: 'taoQtiItem/qtiCommonRenderer/renderers/Img',\n figcaption: 'taoQtiItem/qtiCommonRenderer/renderers/Figcaption',\n math: 'taoQtiItem/qtiCommonRenderer/renderers/Math',\n object: 'taoQtiItem/qtiCommonRenderer/renderers/Object',\n table: 'taoQtiItem/qtiCommonRenderer/renderers/Table',\n printedVariable: 'taoQtiItem/qtiCommonRenderer/renderers/PrintedVariable',\n rubricBlock: 'taoQtiItem/qtiCommonRenderer/renderers/RubricBlock',\n modalFeedback: 'taoQtiItem/qtiCommonRenderer/renderers/ModalFeedback',\n prompt: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/Prompt',\n choiceInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/ChoiceInteraction',\n extendedTextInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/ExtendedTextInteraction',\n orderInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/OrderInteraction',\n associateInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/AssociateInteraction',\n matchInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/MatchInteraction',\n textEntryInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/TextEntryInteraction',\n sliderInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/SliderInteraction',\n inlineChoiceInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/InlineChoiceInteraction',\n 'simpleChoice.choiceInteraction': 'taoQtiItem/qtiCommonRenderer/renderers/choices/SimpleChoice.ChoiceInteraction',\n 'simpleChoice.orderInteraction': 'taoQtiItem/qtiCommonRenderer/renderers/choices/SimpleChoice.OrderInteraction',\n hottext: 'taoQtiItem/qtiCommonRenderer/renderers/choices/Hottext',\n gap: 'taoQtiItem/qtiCommonRenderer/renderers/choices/Gap',\n gapText: 'taoQtiItem/qtiCommonRenderer/renderers/choices/GapText',\n 'simpleAssociableChoice.matchInteraction':\n 'taoQtiItem/qtiCommonRenderer/renderers/choices/SimpleAssociableChoice.MatchInteraction',\n 'simpleAssociableChoice.associateInteraction':\n 'taoQtiItem/qtiCommonRenderer/renderers/choices/SimpleAssociableChoice.AssociateInteraction',\n inlineChoice: 'taoQtiItem/qtiCommonRenderer/renderers/choices/InlineChoice',\n hottextInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/HottextInteraction',\n hotspotInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/HotspotInteraction',\n hotspotChoice: false,\n gapMatchInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/GapMatchInteraction',\n selectPointInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/SelectPointInteraction',\n graphicOrderInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/GraphicOrderInteraction',\n mediaInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/MediaInteraction',\n uploadInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/UploadInteraction',\n graphicGapMatchInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/GraphicGapMatchInteraction',\n gapImg: 'taoQtiItem/qtiCommonRenderer/renderers/choices/GapImg',\n graphicAssociateInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/GraphicAssociateInteraction',\n associableHotspot: false,\n customInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/PortableCustomInteraction',\n infoControl: 'taoQtiItem/qtiCommonRenderer/renderers/PortableInfoControl',\n include: 'taoQtiItem/qtiCommonRenderer/renderers/Include',\n endAttemptInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/EndAttemptInteraction'\n };\n\n var config = {\n name: 'commonRenderer',\n locations: locations,\n options: {\n assetManager: assetManager,\n themes: itemThemes,\n enableDragAndDrop: {\n associate: !!moduleConfig.associateDragAndDrop,\n gapMatch: !!moduleConfig.gapMatchDragAndDrop,\n graphicGapMatch: !!moduleConfig.graphicGapMatchDragAndDrop,\n order: !!moduleConfig.orderDragAndDrop\n },\n messages: moduleConfig.messages\n }\n };\n\n return config;\n\n});\n\n","define('taoQtiItem/qtiCommonRenderer/renderers/Renderer',['taoQtiItem/qtiRunner/core/Renderer', 'taoQtiItem/qtiCommonRenderer/renderers/config'], function (Renderer$1, config) { 'use strict';\n\n\tRenderer$1 = Renderer$1 && Object.prototype.hasOwnProperty.call(Renderer$1, 'default') ? Renderer$1['default'] : Renderer$1;\n\tconfig = config && Object.prototype.hasOwnProperty.call(config, 'default') ? config['default'] : config;\n\n\t/**\n\t * This program is free software; you can redistribute it and/or\n\t * modify it under the terms of the GNU General Public License\n\t * as published by the Free Software Foundation; under version 2\n\t * of the License (non-upgradable).\n\t *\n\t * This program is distributed in the hope that it will be useful,\n\t * but WITHOUT ANY WARRANTY; without even the implied warranty of\n\t * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n\t * GNU General Public License for more details.\n\t *\n\t * You should have received a copy of the GNU General Public License\n\t * along with this program; if not, write to the Free Software\n\t * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n\t *\n\t * Copyright (c) 2014 (original work) Open Assessment Technologies SA;\n\t */\n\n\tvar Renderer = Renderer$1.build(config.locations, config.name, config.options);\n\n\treturn Renderer;\n\n});\n\n","define('taoQtiItem/runner/provider/manager/userModules',['lodash', 'module'], function (_, module) { 'use strict';\n\n _ = _ && Object.prototype.hasOwnProperty.call(_, 'default') ? _['default'] : _;\n module = module && Object.prototype.hasOwnProperty.call(module, 'default') ? module['default'] : module;\n\n /**\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2016 (original work) Open Assessment Technologies SA ;\n */\n\n var userModules = {\n /**\n * Load user modules defined in the module config\n * @param {Array} [userModules] - manually specify user modules to load instead of getting them from the module config\n * @returns {Promise}\n */\n load: function load(userModules) {\n var config = module.config();\n\n if (!userModules || !_.isArray(userModules)) {\n if (config && config.userModules && _.isArray(config.userModules)) {\n userModules = config.userModules;\n } else {\n userModules = [];\n }\n }\n if(!userModules.length){\n return Promise.resolve();\n }\n return new Promise(function(resolve, reject) {\n window.require(userModules, function() {\n _.forEach(arguments, function(dependency) {\n if (dependency && _.isFunction(dependency.exec)) {\n dependency.exec();\n }\n });\n resolve();\n }, function(err) {\n reject(err.message);\n });\n });\n }\n };\n\n return userModules;\n\n});\n\n","/**\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2014 (original work) Open Assessment Technologies SA (under the project TAO-PRODUCT);\n */\ndefine('taoQtiItem/runtime/qtiBootstrap',[\n 'jquery',\n 'lodash',\n 'module',\n 'taoQtiItem/qtiRunner/core/QtiRunner',\n 'taoQtiItem/qtiCommonRenderer/renderers/Renderer',\n 'iframeNotifier',\n 'core/history',\n 'taoQtiItem/runner/provider/manager/userModules'\n], function($, _, module, QtiRunner, Renderer, iframeNotifier, history, userModules){\n 'use strict';\n\n //fix backspace going back into the history\n history.fixBrokenBrowsers();\n\n /**\n * The bootstrap is used to set up a QTI item at runtime. It connects to the itemApi.\n *\n * @author Bertrand Chevrier \n * @exports taoQtiItem/runtime/qtiBootstrap\n *\n * @param {Object} runnerContext - the item context\n */\n return function bootstrap (runnerContext){\n\n //reconnect to global itemApi function\n window.onItemApiReady = function onItemApiReady(itemApi) {\n var qtiRunner = new QtiRunner();\n var coreItemData = runnerContext.itemData;\n var variableElementsData = _.merge(runnerContext.variableElements, itemApi.params.contentVariables || {});\n\n var renderer = new Renderer();\n\n // Makes the runner interface available from outside the frame\n // for preview.\n window.qtiRunner = qtiRunner;\n\n qtiRunner.setItemApi(itemApi);\n qtiRunner.setRenderer(renderer);\n\n qtiRunner.loadItemData(coreItemData, function() {\n\n qtiRunner.loadElements(variableElementsData, function() {\n\n qtiRunner.renderItem(undefined, function() {\n\n //userModules loading\n //we use any user modules bound to this module configuration instead of the ones bound to the new test runner\n var userModulesOverride;\n var config = module.config();\n if (config && config.userModules && _.isArray(config.userModules) && config.userModules.length > 0) {\n userModulesOverride = config.userModules;\n }\n userModules.load(userModulesOverride)\n .then(function() {\n\n //exec user scripts\n if (_.isArray(runnerContext.userScripts)) {\n require(runnerContext.userScripts, function() {\n _.forEach(arguments, function(dependency) {\n if (_.isFunction(dependency.exec)) {\n dependency.exec.call(null, runnerContext.userVars);\n }\n });\n });\n }\n\n iframeNotifier.parent('itemloaded');\n\n //IE9/10 loose the iframe focus, so we force getting it back.\n _.defer(function(){\n window.focus();\n });\n })\n .catch(function(err) {\n throw new Error('Error in user modules : ' + err.message);\n });\n\n });\n });\n });\n };\n\n //if the item is longer to load,\n _.defer(function(){\n //tell the parent to connect the item api\n iframeNotifier.parent('itemready');\n });\n\n };\n});\n\n\n","/**\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2014 (original work) Open Assessment Technologies SA (under the project TAO-PRODUCT);\n */\n\ndefine('taoQtiItem/runtime/qtiLoader',[\n 'taoQtiItem/runtime/qtiBootstrap',\n 'css!taoCss/tao-main-style'\n], function(qtiBootstrap){\n 'use strict';\n\n return {\n start : function start(){\n //the context is set into the template and bound to the tao namespace in global scope\n var runnerContext = window.tao.qtiRunnerContext;\n qtiBootstrap(runnerContext);\n }\n };\n});\n\n","\ndefine(\"taoQtiItem/loader/qtiLoader.bundle\", function(){});\n","window.bundles = (window.bundles || []).concat([\"taoQtiItem/loader/taoQtiItem.min\"]);\n"],"mappings":"ACsBA,YACA,gBAIA,CAAAA,YAAA,CAAAC,QAAA,CAAAC,cAAA,eACAC,SAAA,CAAAH,YAAA,CAAAI,YAAA,gBACAC,MAAA,CAAAL,YAAA,CAAAI,YAAA,gBAEAE,cAAA,UAAAA,eAAA,KACA,CAAAC,iBAAA,IACAC,cAAA,CAAAR,YAAA,CAAAI,YAAA,oBACAK,MAAA,CAAAT,YAAA,CAAAI,YAAA,g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GAAA,EACA,UAAAkH,KAAA,4BAAAlH,GAAA,CAAA+d,OAAA,CACA,EAEA,EACA,EACA,EACA,EAGAxZ,CAAA,CAAA43B,KAAA,YAEAzf,cAAA,CAAA3V,MAAA,aACA,EAEA,CACA,GCzFA5F,MAAA,iCACA,kCACA,4BACA,UAAAk7B,YAAA,EACA,aAEA,OACA/7B,KAAA,UAAAA,MAAA,EAEA,IAAAk7B,aAAA,CAAAv7B,MAAA,CAAAq8B,GAAA,CAAAC,gBAAA,CACAF,YAAA,CAAAb,aAAA,CACA,CACA,CACA,GC9BAr6B,MAAA,oDACAlB,MCFA,CAAAU,OAAA,EAAAV,MAAA,CAAAU,OAAA,MAAAC,MAAA"} \ No newline at end of file +{"version":3,"names":["loaderScript","document","getElementById","configUrl","getAttribute","bundle","loadController","controllerOptions","controllerPath","params","JSON","parse","err","window","require","controller","startController","started","start","addEventListener","readyState","loadBundles","loaded","bundles","concat","filter","item","index","indexOf","forEach","length","define","qtiClasses","_container","assessmentItem","responseProcessing","_simpleFeedbackRule","stylesheet","math","figure","img","figcaption","object","outcomeDeclaration","responseDeclaration","rubricBlock","associableHotspot","gap","gapImg","gapText","hotspotChoice","hottext","inlineChoice","simpleAssociableChoice","simpleChoice","associateInteraction","choiceInteraction","endAttemptInteraction","extendedTextInteraction","gapMatchInteraction","graphicAssociateInteraction","graphicGapMatchInteraction","graphicOrderInteraction","hotspotInteraction","hottextInteraction","inlineChoiceInteraction","matchInteraction","mediaInteraction","orderInteraction","prompt","selectPointInteraction","sliderInteraction","textEntryInteraction","uploadInteraction","feedbackBlock","feedbackInline","modalFeedback","customInteraction","infoControl","include","table","printedVariable","_tooltip","_","Object","prototype","hasOwnProperty","call","util","buildSerial","prefix","id","chars","i","charAt","Math","floor","random","buildId","usedIds","suffix","exists","TypeError","getUsedIds","contains","buildIdentifier","useSuffix","getUsedIdentifiers","isUndefined","replace","findInCollection","element","collectionNames","searchedSerial","found","isString","isArray","each","collectionName","collection","split","nameToken","elt","parent","isFunction","find","Error","addMarkupNamespace","markup","ns","$0","$1","$2","$3","$4","removeMarkupNamespaces","removeMarkupNamespace","getMarkupUsedNamespaces","namespaces","original","slash","node","push","uniq","$","rendererConfigHelper","getOptionsFromArguments","args","options","data","placeholder","subclass","renderer","arg","isRenderer","isPlainObject","console","log","_class","loggerFactory","rendererConfig","_instances","logger","Element","Class","extend","qtiClass","serial","rootElement","init","attributes","metaData","match","setAttributes","initContainer","arguments","initObject","is","getSerial","elts","getComposingElements","attr","name","value","prop","trigger","key","removeData","removeAttr","removeAttributes","warn","getAttributes","clone","attrNames","append","getBody","getObject","v","isA","getUsedClasses","ret","composingElts","body","location","getRootElement","setRelatedItem","setRootElement","getRelatedItem","setRenderer","getRenderer","render","rendering","_renderer","tplData","defaultData","tag","resolveUrl","merge","getData","renderTpl","replaceWith","postRender","altClassName","postRenderers","compact","getContainer","$scope","toArray","arr","type","isEmpty","addClass","className","clazz","_containClass","hasClass","removeClass","regex","RegExp","trim","toggleClass","state","isset","issetElement","unset","unsetElement","allClassStr","test","qtiElement","getElementBySerial","composingElements","getPrefix","html5Ns","prefixed","xmlNsHandler","stripNs","pattern","openRegEx","closeRegEx","restoreNs","xml","ignoreMarkup","xmlCopy","xmlRe","tagRe","xmlMatch","imsXsd","prefixAtt","tagMatch","responseRules","MATCH_CORRECT","responseIdentifier","outcomeIdentifier","responseIf","expression","expressions","identifier","baseType","MAP_RESPONSE","MAP_RESPONSE_POINT","responseRulesHelper","_templateNames","NONE","response","isUsingTemplate","tpl","template","isValidTemplateName","tplName","getTemplateUriFromName","getTemplateNameFromUri","tplUri","forIn","uri","getTemplateNameFromResponseRules","outcomeRules","keys","isEqual","itemScore","responseIdentifiers","outcomeExpressions","map","moduleLoader","responseHelper","itemScoreHelper","loadPortableCustomElementProperties","portableElement","rawProperties","properties","forOwn","e","loadPortableCustomElementData","typeIdentifier","entryPoint","libraries","setNamespace","xmlns","Loader","classesLocation","qti","setClassesLocation","qtiClassesList","getRequiredClasses","union","loadRequiredClasses","callback","reload","requiredClass","requiredClasses","required","module","category","addList","load","then","loadeded","QtiClass","getLoadedClasses","loadItemData","Qti","loadContainer","outcomes","outcome","buildOutcome","addOutcomeDeclaration","feedbacks","feedback","buildElement","addModalFeedback","stylesheets","addStylesheet","responses","responseRuleItemIndex","findIndex","_ref","responseRule","splice","buildResponse","addResponseDeclaration","feedbackRules","fbData","feedbackOutcomeIdentifier","feedbackOutcome","buildSimpleFeedbackRule","feedbackResponseRuleIndex","_ref2","setOutcomeResponseRule","responseKey","customResponseProcessing","some","setResponseProcessing","buildResponseProcessing","setNamespaces","setSchemaLocations","schemaLocations","setApipAccessibility","apipAccessibility","loadAndBuildElement","loadElement","loadElementData","loadElements","allElements","elementData","howMatch","defaultValue","correctResponse","correctResponses","mapEntries","size","mapping","areaMapping","mappingAttributes","feedbackRule","setCondition","condition","comparedValue","feedbackThen","modalFeedbacks","feedbackElse","comparedOutcome","rp","processingType","bodyObject","bodyData","elements","defaults","eltData","setElement","text","bdy","loadObjectData","loadInteractionData","loadChoiceData","loadMathData","loadPicData","loadTooltipData","interaction","buildInteractionChoices","loadPciData","choices","set","matchSet","choice","addChoice","gapImgs","addGapImg","val","_alt","setMathML","mathML","annotations","encoding","setAnnotation","tooltip","content","pci","pic","getRawValues","pciVar","base","values","list","_checkContainerType","_getBodyDom","html","_setBodyDomClass","newClass","oldClass","$wrapper","_setDomClass","$bodyDom","wrapInner","setEncodedDataToDom","dataName","newValue","oldValue","_getEncodedDataString","setEncodedData","getEncodedData","removeEncodedData","hasEncodedData","$body","matches","_prefix","container","$$1","context","containerHelper","Handlebars","Helpers0","iframeNotifier","previewOkBtn","asString","Template","deliveryOkBtn","Template$1","showFeedbacks","loader","itemSession","onCloseCallback","onShowCallback","firstFeedback","interactionsDisplayInfo","getInteractionsDisplayInfo","messages","renderedFeebacks","renderingQueue","$itemContainer","$itemBody","children","feedbackIds","message","$container","_currentMessageGroupId","interactionInfo","order","getFeedbackMessageSignature","displayContainer","messageGroupId","sortBy","clearModalFeedbacks","renderingToken","renderModalFeedback","renderingData","dom","on","autoscroll","replaceControl","getQtiContainer","me","max","__knownParent__","currentScrollTop","minScrollTop","maxScrollTop","scrollTop","$element","offset","top","height","outerHeight","min","animate","extractDisplayInfo","$displayContainer","$interactionContainer","closest","uniqueId","interactionContainer","interactionOrder","_interactionInfo","remove","renderedCallback","$modalFeedback","inline","done","Promise","race","all","pop","resolve","reject","delay","timeout","catch","$controls","$toggleContainer","parents","initControlToggle","toggleButtonTemplate","$ok","click","fb","hide","uncover","show","cover","interactionContainers","$cover","$interaction","toLowerCase","__initialized","depth0","helpers","partials","compilerInfo","helper","buffer","helperMissing","escapeExpression","__","hash","inlineRenderer","async","count","feedbacksToBeDisplayed","callstack","eachRight","endCallback","cb","series","closeCallback","$feedback","$feedbackBox","modal","modalRenderer","ItemLoader","modalFeedbackInline","modalFeedbackModal","QtiRunner","rpEngine","itemApi","updateItemApi","getResponses","states","getStates","variables","property","file","mime","setVariables","saveResponses","resultApi","setQtiRunner","setItemApi","that","oldStateVariables","stringify","stateVariables","onKill","killCallback","newStateVariables","serviceApi","getHasBeenPaused","submit","setHasBeenPaused","getLoader","self","renderItem","noop","initInteractionsResponse","listenForThemeChange","interactions","getInteractions","responseId","getVariable","setState","setVariable","off","themeName","themeLoader","getThemeLoader","originalEvent","detail","change","validate","finish","getResponse","error","getState","inlineDisplay","config","inlineModalFeedback","_Mathfloor","interactionHelper","convertChoices","outputType","_this","c","findChoices","inputType","getChoice","getChoiceByIdentifier","shuffleChoices","r","f","j","n","k","tmp","serialToIdentifier","choiceSerial","themesHelper","getDocumentBaseUrl","protocol","host","pathname","hb","compile","_renderableClasses","_dependencies","_renderableSubclasses","_defaults","_isValidRenderer","valid","classCorrect","pos","slice","subClass","Renderer","registerRendererClass","success","_locations","_renderers","shuffledChoices","_getClassRenderer","setOption","setOptions","opts","getOption","getCustomMessage","elementName","messageKey","getAssetManager","assetManager","qtiSubclass","res","decorators","isObject","before","after","renderDirect","setResponse","qtiInteraction","resetResponse","destroy","getLoadedRenderers","register","renderersLocations","themeData","getCurrentThemeData","themes","available","theme","path","preload","intersection","reqClass","deps","requiredSubClasses","unload","setShuffledChoices","identificationType","pluck","getShuffledChoices","reshuffle","returnedType","getChoices","getRenderers","getLocations","url","getAbsoluteUrl","relUrl","absUrl","runtimeLocations","runtimeLocation","baseUrl","setAreaBroker","areaBroker","_areaBroker","getAreaBroker","getItemCreator","Renderer$1","build","defaultOptions","NewRenderer","apply","eventifier","_requirejs","_defaultLoadingOptions","loadModuleConfig","manifest","requireConfigAliases","reqConfigs","modules","runtime","pciConfig","paths","runtimeModules","model","reduce","acc","conf","isPortableElementProvider","provider","portableElementRegistry","methods","_loaded","__providers","_registry","get","version","last","registerProvider","moduleName","resetProviders","loadProviders","loadPromise","providerLoadingStack","shift","getAllVersions","versions","getRuntime","assign","label","getCreator","creator","getLatestCreators","lastVersion","hook","enabled","getBaseUrl","loadRuntimes","providers","loadStack","results","configLoadingStack","_pcis","moduleConfigs","loadCreators","requiredCreatorHooks","portableElementModel","creators","creatorHook","getTypeIdentifier","enable","disable","isEnabled","featuresService","QtiElements","classes","itemBody","abstract","atomicBlock","atomicInline","simpleBlock","simpleInline","flowStatic","blockStatic","inlineStatic","flow","tableCell","caption","xhtml","col","colgroup","div","dl","dt","dd","hr","li","ol","ul","param","tbody","tfoot","thead","td","th","tr","a","abbr","acronym","b","big","cite","code","dfn","em","kbd","q","samp","small","span","strong","sub","sup","tt","var","blockquote","address","h1","h2","h3","h4","h5","h6","p","pre","br","textRun","blockInteraction","inlineInteraction","templateElement","templateBlock","templateInline","drawingInteraction","graphicInteraction","cache","containable","getAllowedContainersElements","getAllowedContainers","jqSelector","substring","getParentClasses","aClass","intersect","getChildClasses","getAllowedContents","recursive","checked","contain","child","isAllowedClass","qtiContainerClass","qtiContentClass","allowedClasses","cacheType","isBlock","isInline","topClass","isVisible","getAvailableAuthoringElements","tagTitles","commonInteractions","inlineInteractions","graphicInteractions","authoringElements","description","icon","short","tags","group","availableElements","elementId","entries","qtiElements","customInteractionRegistry","getAuthoringData","enabledOnly","pciModel","ciRegistry","registry","infoControlRegistry","icRegistry","getBaseUrlByIdentifier","handle","handlePortableElementLocation","source","relative","fullmatch","relPath","assetManagerFactory","assetStrategies","portableAssetStrategy","itemThemes","moduleConfig","handleTheme","root_url","toString","taomedia","external","base64","itemCssNoCache","locations","\"simpleChoice.choiceInteraction\"","\"simpleChoice.orderInteraction\"","\"simpleAssociableChoice.matchInteraction\"","\"simpleAssociableChoice.associateInteraction\"","enableDragAndDrop","associate","associateDragAndDrop","gapMatch","gapMatchDragAndDrop","graphicGapMatch","graphicGapMatchDragAndDrop","orderDragAndDrop","userModules","dependency","exec","history","fixBrokenBrowsers","bootstrap","runnerContext","onItemApiReady","qtiRunner","coreItemData","itemData","variableElementsData","variableElements","contentVariables","userModulesOverride","userScripts","userVars","defer","focus","qtiBootstrap","tao","qtiRunnerContext"],"sources":["/Users/andrey.shaveko/Projects/tao-community-2023-08-2/tao/views/build/config-wrap-start-default.js","../../loader/bootstrap.js","../qtiItem/core/qtiClasses.js","../qtiItem/helper/util.js","../qtiItem/helper/rendererConfig.js","../qtiItem/core/Element.js","../qtiItem/helper/xmlNsHandler.js","../qtiItem/helper/responseRules.js","../qtiItem/helper/response.js","../qtiItem/helper/itemScore.js","../qtiItem/core/Loader.js","../qtiItem/helper/pci.js","../qtiItem/helper/container.js","../qtiRunner/modalFeedback/inlineRenderer.js","../qtiRunner/modalFeedback/modalRenderer.js","../qtiRunner/core/QtiRunner.js","../qtiItem/helper/interactionHelper.js","../qtiRunner/core/Renderer.js","../portableElementRegistry/factory/factory.js","../qtiCreator/helper/qtiElements.js","../portableElementRegistry/factory/ciRegistry.js","../portableElementRegistry/ciRegistry.js","../portableElementRegistry/factory/icRegistry.js","../portableElementRegistry/icRegistry.js","../portableElementRegistry/assetManager/portableAssetStrategy.js","../qtiCommonRenderer/renderers/config.js","../qtiCommonRenderer/renderers/Renderer.js","../runner/provider/manager/userModules.js","../runtime/qtiBootstrap.js","../runtime/qtiLoader.js","module-create.js","/Users/andrey.shaveko/Projects/tao-community-2023-08-2/tao/views/build/config-wrap-end-default.js"],"sourcesContent":["\n","/**\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2016-2018 (original work) Open Assessment Technologies SA ;\n */\n\n/**\n * Bootstrap the app, start the entry controller\n * @author Bertrand Chevrier \n */\n(function(){\n 'use strict';\n\n\n\n var loaderScript = document.getElementById('amd-loader');\n var configUrl = loaderScript.getAttribute('data-config');\n var bundle = loaderScript.getAttribute('data-bundle');\n\n var loadController = function loadController(){\n var controllerOptions = {};\n var controllerPath = loaderScript.getAttribute('data-controller');\n var params = loaderScript.getAttribute('data-params');\n try{\n controllerOptions = JSON.parse(params);\n } catch(err){\n controllerOptions = {};\n }\n window.require([controllerPath], function(controller) {\n var startController = function startController(){\n if(!window.started){\n window.started = true;\n controller.start(controllerOptions);\n }\n };\n document.addEventListener('readystatechange', startController, false);\n if (document.readyState === 'complete') {\n startController();\n }\n });\n };\n\n //always start to load the config\n window.require([configUrl], function() {\n\n //define the global loading mechanism\n if(!window.loadBundles){\n //keep tracl of loaded bundles, even if require does it,\n //this prevent some unecessary cycles\n window.loaded = {};\n\n /**\n * Loading entry point for inter bundle dependency,\n * always take the bundles from the params and window.bundles\n * @param {String[]} [bundles] - an optional list of bundle to load\n */\n window.loadBundles = function loadBundles(bundles){\n bundles = bundles || [];\n bundles = bundles.concat(window.bundles)\n bundles = bundles.filter( function(item, index){\n return item && bundles.indexOf(item) === index && window.loaded[item] !== true;\n });\n require(bundles, function(){\n bundles.forEach( function( item ) {\n window.loaded[item] = true;\n });\n loadController();\n });\n }\n }\n\n if(bundle || (window.bundles && window.bundles.length)) {\n window.loadBundles([bundle]);\n } else {\n loadController();\n }\n });\n})();\n\ndefine(\"loader/bootstrap\", function(){});\n\n","define('taoQtiItem/qtiItem/core/qtiClasses',[],function () { 'use strict';\n\n var qtiClasses = {\n _container: 'taoQtiItem/qtiItem/core/Container',\n assessmentItem: 'taoQtiItem/qtiItem/core/Item',\n responseProcessing: 'taoQtiItem/qtiItem/core/ResponseProcessing',\n _simpleFeedbackRule: 'taoQtiItem/qtiItem/core/response/SimpleFeedbackRule',\n stylesheet: 'taoQtiItem/qtiItem/core/Stylesheet',\n math: 'taoQtiItem/qtiItem/core/Math',\n figure: 'taoQtiItem/qtiItem/core/Figure',\n img: 'taoQtiItem/qtiItem/core/Img',\n figcaption: 'taoQtiItem/qtiItem/core/Figcaption',\n object: 'taoQtiItem/qtiItem/core/Object',\n outcomeDeclaration: 'taoQtiItem/qtiItem/core/variables/OutcomeDeclaration',\n responseDeclaration: 'taoQtiItem/qtiItem/core/variables/ResponseDeclaration',\n rubricBlock: 'taoQtiItem/qtiItem/core/RubricBlock',\n associableHotspot: 'taoQtiItem/qtiItem/core/choices/AssociableHotspot',\n gap: 'taoQtiItem/qtiItem/core/choices/Gap',\n gapImg: 'taoQtiItem/qtiItem/core/choices/GapImg',\n gapText: 'taoQtiItem/qtiItem/core/choices/GapText',\n hotspotChoice: 'taoQtiItem/qtiItem/core/choices/HotspotChoice',\n hottext: 'taoQtiItem/qtiItem/core/choices/Hottext',\n inlineChoice: 'taoQtiItem/qtiItem/core/choices/InlineChoice',\n simpleAssociableChoice: 'taoQtiItem/qtiItem/core/choices/SimpleAssociableChoice',\n simpleChoice: 'taoQtiItem/qtiItem/core/choices/SimpleChoice',\n associateInteraction: 'taoQtiItem/qtiItem/core/interactions/AssociateInteraction',\n choiceInteraction: 'taoQtiItem/qtiItem/core/interactions/ChoiceInteraction',\n endAttemptInteraction: 'taoQtiItem/qtiItem/core/interactions/EndAttemptInteraction',\n extendedTextInteraction: 'taoQtiItem/qtiItem/core/interactions/ExtendedTextInteraction',\n gapMatchInteraction: 'taoQtiItem/qtiItem/core/interactions/GapMatchInteraction',\n graphicAssociateInteraction: 'taoQtiItem/qtiItem/core/interactions/GraphicAssociateInteraction',\n graphicGapMatchInteraction: 'taoQtiItem/qtiItem/core/interactions/GraphicGapMatchInteraction',\n graphicOrderInteraction: 'taoQtiItem/qtiItem/core/interactions/GraphicOrderInteraction',\n hotspotInteraction: 'taoQtiItem/qtiItem/core/interactions/HotspotInteraction',\n hottextInteraction: 'taoQtiItem/qtiItem/core/interactions/HottextInteraction',\n inlineChoiceInteraction: 'taoQtiItem/qtiItem/core/interactions/InlineChoiceInteraction',\n matchInteraction: 'taoQtiItem/qtiItem/core/interactions/MatchInteraction',\n mediaInteraction: 'taoQtiItem/qtiItem/core/interactions/MediaInteraction',\n orderInteraction: 'taoQtiItem/qtiItem/core/interactions/OrderInteraction',\n prompt: 'taoQtiItem/qtiItem/core/interactions/Prompt',\n selectPointInteraction: 'taoQtiItem/qtiItem/core/interactions/SelectPointInteraction',\n sliderInteraction: 'taoQtiItem/qtiItem/core/interactions/SliderInteraction',\n textEntryInteraction: 'taoQtiItem/qtiItem/core/interactions/TextEntryInteraction',\n uploadInteraction: 'taoQtiItem/qtiItem/core/interactions/UploadInteraction',\n feedbackBlock: 'taoQtiItem/qtiItem/core/feedbacks/FeedbackBlock',\n feedbackInline: 'taoQtiItem/qtiItem/core/feedbacks/FeedbackInline',\n modalFeedback: 'taoQtiItem/qtiItem/core/feedbacks/ModalFeedback',\n customInteraction: 'taoQtiItem/qtiItem/core/interactions/CustomInteraction',\n infoControl: 'taoQtiItem/qtiItem/core/PortableInfoControl',\n include: 'taoQtiItem/qtiItem/core/Include',\n table: 'taoQtiItem/qtiItem/core/Table',\n printedVariable: 'taoQtiItem/qtiItem/core/PrintedVariable',\n _tooltip: 'taoQtiItem/qtiItem/core/Tooltip'\n };\n\n return qtiClasses;\n\n});\n\n","define('taoQtiItem/qtiItem/helper/util',['lodash'], function (_) { 'use strict';\n\n _ = _ && Object.prototype.hasOwnProperty.call(_, 'default') ? _['default'] : _;\n\n /*\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2015 (original work) Open Assessment Technologies SA\n *\n */\n\n var util = {\n buildSerial: function buildSerial(prefix) {\n var id = prefix || '';\n var chars = 'abcdefghijklmnopqrstuvwxyz0123456789';\n for (var i = 0; i < 22; i++) {\n id += chars.charAt(Math.floor(Math.random() * chars.length));\n }\n return id;\n },\n\n /**\n * Generates an id for a Qti element (the generation is different from identifier)\n * @param {Object} item - the element related item\n * @param {String} prefix - identifier prefix\n * @returns {String} the identifier\n * @throws {TypeError} if there is no item\n */\n buildId: function buildId(item, prefix) {\n var id;\n var usedIds;\n var i = 1;\n var suffix = '';\n var exists = false;\n\n if (!item) {\n throw new TypeError('A item is required to generate a unique identifier');\n }\n\n usedIds = item.getUsedIds();\n\n do {\n exists = false;\n id = prefix + suffix;\n if (_.contains(usedIds, id)) {\n exists = true;\n suffix = '_' + i;\n i++;\n }\n } while (exists);\n\n return id;\n },\n\n /**\n * Generates an identifier for a Qti element\n * @param {Object} item - the element related item\n * @param {String} prefix - identifier prefix\n * @param {Boolean} [useSuffix = true] - add a \"_ + index\" to the identifier\n * @returns {String} the identifier\n * @throws {TypeError} if there is no item\n */\n buildIdentifier: function buildIdentifier(item, prefix, useSuffix) {\n var id;\n var usedIds;\n var suffix = '';\n var i = 1;\n var exists = false;\n\n if (!item) {\n throw new TypeError('A item is required to generate a unique identifier');\n }\n\n if (!prefix) {\n throw new TypeError('Prefix is required to build an identifier');\n }\n\n usedIds = item.getUsedIdentifiers();\n useSuffix = _.isUndefined(useSuffix) ? true : useSuffix;\n\n if (prefix) {\n prefix = prefix\n .replace(/_[0-9]+$/gi, '_') //detect incremental id of type choice_12, response_3, etc.\n .replace(/[^a-zA-Z0-9_]/gi, '_')\n .replace(/(_)+/gi, '_');\n if (useSuffix) {\n suffix = '_' + i;\n }\n }\n\n do {\n exists = false;\n id = prefix + suffix;\n if (usedIds[id]) {\n exists = true;\n suffix = '_' + i;\n i++;\n }\n } while (exists);\n\n return id;\n },\n\n findInCollection: function findInCollection(element, collectionNames, searchedSerial) {\n var found = null;\n\n if (_.isString(collectionNames)) {\n collectionNames = [collectionNames];\n }\n\n if (_.isArray(collectionNames)) {\n _.each(collectionNames, function(collectionName) {\n //get collection to search in (resolving case like interaction.choices.0\n var collection = element;\n _.each(collectionName.split('.'), function(nameToken) {\n collection = collection[nameToken];\n });\n var elt = collection[searchedSerial];\n\n if (elt) {\n found = { parent: element, element: elt };\n return false; //break the each loop\n }\n\n //search inside each elements:\n _.each(collection, function(elt) {\n if (_.isFunction(elt.find)) {\n found = elt.find(searchedSerial);\n if (found) {\n return false; //break the each loop\n }\n }\n });\n\n if (found) {\n return false; //break the each loop\n }\n });\n } else {\n throw new Error('invalid argument : collectionNames must be an array or a string');\n }\n\n return found;\n },\n addMarkupNamespace: function addMarkupNamespace(markup, ns) {\n if (ns) {\n markup = markup.replace(/<(\\/)?([a-z:]+)(\\s?)([^><]*)>/g, function($0, $1, $2, $3, $4) {\n if ($2.indexOf(':') > 0) {\n return $0;\n }\n $1 = $1 || '';\n $3 = $3 || '';\n return '<' + $1 + ns + ':' + $2 + $3 + $4 + '>';\n });\n return markup;\n }\n return markup;\n },\n removeMarkupNamespaces: function removeMarkupNamespace(markup) {\n return markup.replace(/<(\\/)?(\\w*):([^>]*)>/g, '<$1$3>');\n },\n getMarkupUsedNamespaces: function getMarkupUsedNamespaces(markup) {\n var namespaces = [];\n markup.replace(/<(\\/)?(\\w*):([^>]*)>/g, function(original, slash, ns, node) {\n namespaces.push(ns);\n return '<' + slash + node + '>';\n });\n return _.uniq(namespaces);\n }\n };\n\n return util;\n\n});\n\n","define('taoQtiItem/qtiItem/helper/rendererConfig',['lodash', 'jquery'], function (_, $) { 'use strict';\n\n _ = _ && Object.prototype.hasOwnProperty.call(_, 'default') ? _['default'] : _;\n $ = $ && Object.prototype.hasOwnProperty.call($, 'default') ? $['default'] : $;\n\n var rendererConfigHelper = {};\n\n rendererConfigHelper.getOptionsFromArguments = function(args) {\n var options = {\n data: {},\n placeholder: null,\n subclass: '',\n renderer: null\n };\n\n _.each(args, function(arg) {\n if (arg) {\n if (arg.isRenderer) {\n options.renderer = arg;\n } else if (arg instanceof $ && arg.length) {\n options.placeholder = arg;\n } else if (_.isString(arg)) {\n options.subclass = arg;\n } else if (_.isPlainObject(arg)) {\n options.data = arg;\n } else {\n console.log('invalid arg', arg, args);\n }\n }\n });\n\n return options;\n };\n\n return rendererConfigHelper;\n\n});\n\n","define('taoQtiItem/qtiItem/core/Element',['jquery', 'lodash', 'class', 'core/logger', 'taoQtiItem/qtiItem/helper/util', 'taoQtiItem/qtiItem/helper/rendererConfig'], function ($, _, _class, loggerFactory, util, rendererConfig) { 'use strict';\n\n $ = $ && Object.prototype.hasOwnProperty.call($, 'default') ? $['default'] : $;\n _ = _ && Object.prototype.hasOwnProperty.call(_, 'default') ? _['default'] : _;\n loggerFactory = loggerFactory && Object.prototype.hasOwnProperty.call(loggerFactory, 'default') ? loggerFactory['default'] : loggerFactory;\n util = util && Object.prototype.hasOwnProperty.call(util, 'default') ? util['default'] : util;\n rendererConfig = rendererConfig && Object.prototype.hasOwnProperty.call(rendererConfig, 'default') ? rendererConfig['default'] : rendererConfig;\n\n /*\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2015 (original work) Open Assessment Technologies SA\n *\n */\n\n var _instances = {};\n\n /**\n * Create a logger\n */\n var logger = loggerFactory('taoQtiItem/qtiItem/core/Element');\n\n var Element = Class.extend({\n qtiClass: '',\n serial: '',\n rootElement: null,\n init: function(serial, attributes) {\n //init own attributes\n this.attributes = {};\n\n //system properties, for item creator internal use only\n this.metaData = {};\n\n //init call in the format init(attributes)\n if (typeof serial === 'object') {\n attributes = serial;\n serial = '';\n }\n\n if (!serial) {\n serial = util.buildSerial(this.qtiClass + '_');\n }\n\n if (serial && (typeof serial !== 'string' || !serial.match(/^[a-z_0-9]*$/i))) {\n throw 'invalid QTI serial : (' + typeof serial + ') ' + serial;\n }\n\n if (!_instances[serial]) {\n _instances[serial] = this;\n this.serial = serial;\n this.setAttributes(attributes || {});\n } else {\n throw 'a QTI Element with the same serial already exists ' + serial;\n }\n\n if (typeof this.initContainer === 'function') {\n this.initContainer(arguments[2] || '');\n }\n if (typeof this.initObject === 'function') {\n this.initObject();\n }\n },\n is: function(qtiClass) {\n return qtiClass === this.qtiClass;\n },\n placeholder: function() {\n return '{{' + this.serial + '}}';\n },\n getSerial: function() {\n return this.serial;\n },\n getUsedIdentifiers: function() {\n var usedIds = {};\n var elts = this.getComposingElements();\n for (var i in elts) {\n var elt = elts[i];\n var id = elt.attr('identifier');\n if (id) {\n //warning: simplistic implementation, allow only one unique identifier in the item no matter the element class/type\n usedIds[id] = elt;\n }\n }\n return usedIds;\n },\n\n /**\n * Get the ids in use. (id is different from identifier)\n * @returns {Array} of the ids in use\n */\n getUsedIds: function getUsedIds() {\n var usedIds = [];\n _.forEach(this.getComposingElements(), function(elt) {\n var id = elt.attr('id');\n if (id && !_.contains(usedIds, id)) {\n usedIds.push(id);\n }\n });\n return usedIds;\n },\n\n attr: function(name, value) {\n if (name) {\n if (value !== undefined) {\n this.attributes[name] = value;\n } else {\n if (typeof name === 'object') {\n for (var prop in name) {\n this.attr(prop, name[prop]);\n }\n } else if (typeof name === 'string') {\n if (this.attributes[name] === undefined) {\n return undefined;\n } else {\n return this.attributes[name];\n }\n }\n }\n }\n return this;\n },\n data: function(name, value) {\n if (name) {\n if (value !== undefined) {\n this.metaData[name] = value;\n $(document).trigger('metaChange.qti-widget', { element: this, key: name, value: value });\n } else {\n if (typeof name === 'object') {\n for (var prop in name) {\n this.data(prop, name[prop]);\n }\n } else if (typeof name === 'string') {\n if (this.metaData[name] === undefined) {\n return undefined;\n } else {\n return this.metaData[name];\n }\n }\n }\n }\n return this;\n },\n removeData: function(name) {\n delete this.metaData[name];\n return this;\n },\n removeAttr: function(name) {\n return this.removeAttributes(name);\n },\n setAttributes: function(attributes) {\n if (!_.isPlainObject(attributes)) {\n logger.warn('attributes should be a plain object');\n }\n this.attributes = attributes;\n return this;\n },\n getAttributes: function() {\n return _.clone(this.attributes);\n },\n removeAttributes: function(attrNames) {\n if (typeof attrNames === 'string') {\n attrNames = [attrNames];\n }\n for (var i in attrNames) {\n delete this.attributes[attrNames[i]];\n }\n return this;\n },\n getComposingElements: function() {\n var elts = {};\n function append(element) {\n elts[element.getSerial()] = element; //pass individual object by ref, instead of the whole list(object)\n elts = _.extend(elts, element.getComposingElements());\n }\n if (typeof this.initContainer === 'function') {\n append(this.getBody());\n }\n if (typeof this.initObject === 'function') {\n append(this.getObject());\n }\n _.each(this.metaData, function(v) {\n if (Element.isA(v, '_container')) {\n append(v);\n } else if (_.isArray(v)) {\n _.each(v, function(v) {\n if (Element.isA(v, '_container')) {\n append(v);\n }\n });\n }\n });\n return elts;\n },\n getUsedClasses: function() {\n var ret = [this.qtiClass],\n composingElts = this.getComposingElements();\n\n _.each(composingElts, function(elt) {\n ret.push(elt.qtiClass);\n });\n\n return _.uniq(ret);\n },\n find: function(serial) {\n var found = null;\n var object, body;\n\n if (typeof this.initObject === 'function') {\n object = this.getObject();\n if (object.serial === serial) {\n found = { parent: this, element: object, location: 'object' };\n }\n }\n\n if (!found && typeof this.initContainer === 'function') {\n body = this.getBody();\n if (body.serial === serial) {\n found = { parent: this, element: body, location: 'body' };\n } else {\n found = this.getBody().find(serial, this);\n }\n }\n\n return found;\n },\n parent: function() {\n var item = this.getRootElement();\n if (item) {\n var found = item.find(this.getSerial());\n if (found) {\n return found.parent;\n }\n }\n return null;\n },\n /**\n * @deprecated - use setRootElement() instead\n */\n setRelatedItem: function(item) {\n logger.warn('Deprecated use of setRelatedItem()');\n this.setRootElement(item);\n },\n setRootElement: function(item) {\n var composingElts, i;\n\n if (Element.isA(item, 'assessmentItem')) {\n this.rootElement = item;\n composingElts = this.getComposingElements();\n for (i in composingElts) {\n composingElts[i].setRootElement(item);\n }\n }\n },\n /**\n * @deprecated - use getRootElement() instead\n */\n getRelatedItem: function() {\n logger.warn('Deprecated use of getRelatedItem()');\n return this.getRootElement();\n },\n getRootElement: function() {\n var ret = null;\n if (Element.isA(this.rootElement, 'assessmentItem')) {\n ret = this.rootElement;\n }\n return ret;\n },\n setRenderer: function(renderer) {\n if (renderer && renderer.isRenderer) {\n this.renderer = renderer;\n var elts = this.getComposingElements();\n for (var serial in elts) {\n elts[serial].setRenderer(renderer);\n }\n } else {\n throw 'invalid qti rendering engine';\n }\n },\n getRenderer: function() {\n return this.renderer;\n },\n /**\n * Render the element. Arguments are all optional and can be given in any order.\n * Argument parsing is based on argument type and is done by taoQtiItem/qtiItem/core/helpers/rendererConfig\n * @param {Renderer} renderer - specify which renderer to use\n * @param {jQuery} placeholder - DOM element that will be replaced by the rendered element\n * @param {Object} data - template data for the rendering\n * @param {String} subclass - subclass enables different behaviour of the same qti class in different contexts (eg. we could have different rendering for simpleChoice according to where it is being used: simpleChoice.orderInteraction, simpleChoice.choiceInteraction...)\n * @returns {String} - the rendered element as an HTML string\n */\n render: function render() {\n var args = rendererConfig.getOptionsFromArguments(arguments);\n var _renderer = args.renderer || this.getRenderer();\n var rendering;\n\n var tplData = {},\n defaultData = {\n tag: this.qtiClass,\n serial: this.serial,\n attributes: this.getAttributes()\n };\n\n if (!_renderer) {\n throw new Error('render: no renderer found for the element ' + this.qtiClass + ':' + this.serial);\n }\n\n if (typeof this.initContainer === 'function') {\n //allow body to have a different renderer if it has its own renderer set\n defaultData.body = this.getBody().render(args.renderer);\n }\n if (typeof this.initObject === 'function') {\n defaultData.object = {\n attributes: this.object.getAttributes()\n };\n defaultData.object.attributes.data = _renderer.resolveUrl(this.object.attr('data'));\n }\n\n tplData = _.merge(defaultData, args.data || {});\n tplData = _renderer.getData(this, tplData, args.subclass);\n rendering = _renderer.renderTpl(this, tplData, args.subclass);\n if (args.placeholder) {\n args.placeholder.replaceWith(rendering);\n }\n\n return rendering;\n },\n postRender: function(data, altClassName, renderer) {\n var postRenderers = [];\n var _renderer = renderer || this.getRenderer();\n\n if (typeof this.initContainer === 'function') {\n //allow body to have a different renderer if it has its own renderer set\n postRenderers = this.getBody().postRender(data, '', renderer);\n }\n\n if (_renderer) {\n postRenderers.push(_renderer.postRender(this, data, altClassName));\n } else {\n throw 'postRender: no renderer found for the element ' + this.qtiClass + ':' + this.serial;\n }\n\n return _.compact(postRenderers);\n },\n getContainer: function($scope, subclass) {\n var renderer = this.getRenderer();\n if (renderer) {\n return renderer.getContainer(this, $scope, subclass);\n } else {\n throw 'getContainer: no renderer found for the element ' + this.qtiClass + ':' + this.serial;\n }\n },\n toArray: function() {\n var arr = {\n serial: this.serial,\n type: this.qtiClass,\n attributes: this.getAttributes()\n };\n\n if (typeof this.initContainer === 'function') {\n arr.body = this.getBody().toArray();\n }\n if (typeof this.initObject === 'function') {\n arr.object = this.object.toArray();\n }\n\n return arr;\n },\n isEmpty: function() {\n //tells whether the element should be considered empty or not, from the rendering point of view\n return false;\n },\n addClass: function(className) {\n var clazz = this.attr('class') || '';\n if (!_containClass(clazz, className)) {\n this.attr('class', clazz + (clazz.length ? ' ' : '') + className);\n }\n },\n hasClass: function(className) {\n return _containClass(this.attr('class'), className);\n },\n removeClass: function(className) {\n var clazz = this.attr('class') || '';\n if (clazz) {\n var regex = new RegExp('(?:^|\\\\s)' + className + '(?:\\\\s|$)');\n clazz = clazz.replace(regex, ' ').trim();\n\n if (clazz) {\n this.attr('class', clazz);\n } else {\n this.removeAttr('class');\n }\n }\n },\n /**\n * Add or remove class. Setting the optional state will force addition/removal.\n * State is here to keep the jQuery syntax\n *\n * @param {String} className\n * @param {Boolean} [state]\n */\n toggleClass: function(className, state) {\n if (typeof state === 'boolean') {\n return state ? this.addClass(className) : this.removeClass(className);\n }\n\n if (this.hasClass(className)) {\n return this.removeClass(className);\n }\n return this.addClass(className);\n },\n isset: function() {\n return Element.issetElement(this.serial);\n },\n unset: function() {\n return Element.unsetElement(this.serial);\n }\n });\n\n var _containClass = function(allClassStr, className) {\n var regex = new RegExp('(?:^|\\\\s)' + className + '(?:\\\\s|$)', '');\n return allClassStr && regex.test(allClassStr);\n };\n\n //helpers\n Element.isA = function(qtiElement, qtiClass) {\n return qtiElement instanceof Element && qtiElement.is(qtiClass);\n };\n\n Element.getElementBySerial = function(serial) {\n return _instances[serial];\n };\n\n Element.issetElement = function(serial) {\n return !!_instances[serial];\n };\n\n /**\n * Unset a registered element from it's serial\n * @param {String} serial - the element serial\n * @returns {Boolean} true if unset\n */\n Element.unsetElement = function(serial) {\n var element = Element.getElementBySerial(serial);\n\n if (element) {\n var composingElements = element.getComposingElements();\n _.each(composingElements, function(elt) {\n delete _instances[elt.serial];\n });\n delete _instances[element.serial];\n\n return true;\n }\n return false;\n };\n\n return Element;\n\n});\n\n","define('taoQtiItem/qtiItem/helper/xmlNsHandler',[],function () { 'use strict';\n\n /*\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2017-2022 (original work) Open Assessment Technologies SA\n */\n\n /**\n * XML namespace handling\n */\n\n /**\n * Elements that need to be prefixed\n *\n * @see http://www.imsglobal.org/xsd/qti/qtiv2p2/imsqti_v2p2.xsd\n * @type {string}\n */\n const prefixed = 'article|aside|bdi|figure|footer|header|nav|rb|rp|rt|rtc|ruby|section';\n\n /**\n * Find a possibly existing prefix\n *\n * @param namespaces\n * @param html5Ns\n * @returns {*}\n */\n function getPrefix(namespaces, html5Ns) {\n let key;\n for (key in namespaces) {\n if (namespaces[key] === html5Ns) {\n return key;\n }\n }\n return 'qh5';\n }\n\n var xmlNsHandler = {\n /**\n * Remove prefix to make sure elements are properly displayed\n *\n * @param body\n */\n stripNs: function stripNs(body) {\n const pattern = '([\\\\w]+)\\\\:(' + prefixed + ')';\n const openRegEx = new RegExp('(<' + pattern + ')', 'gi');\n const closeRegEx = new RegExp('(<\\\\/' + pattern + '>)', 'gi');\n return body.replace(openRegEx, '<$3').replace(closeRegEx, '');\n },\n\n /**\n * Add a prefix to those elements that require one\n *\n * @param xml\n * @param namespaces\n * @returns {*}\n */\n restoreNs: function restoreNs(xml, namespaces, ignoreMarkup = false) {\n let xmlCopy = xml;\n if (ignoreMarkup) {\n // cut from xmlCopy ...\n // because markup should be html without namespace qh5\n xmlCopy = xml.replace(/((?=)+)/gim, '');\n }\n const xmlRe = new RegExp('(<(' + prefixed + ')[^>]*>|<\\\\/(' + prefixed + ')>)', 'gi');\n const tagRe = new RegExp('((<)(' + prefixed + ')([^>]*)(>)|(<\\\\/)(' + prefixed + ')(>))', 'i');\n const xmlMatch = xmlCopy.match(xmlRe);\n const imsXsd = 'http://www.imsglobal.org/xsd';\n const html5Ns = imsXsd + '/imsqtiv2p2_html5_v1p0';\n const prefix = getPrefix(namespaces, html5Ns);\n const prefixAtt = 'xmlns:' + prefix + '=\"' + html5Ns + '\"';\n let i = xmlMatch ? xmlMatch.length : 0;\n\n if (!xmlMatch) {\n return xml;\n }\n\n while (i--) {\n const tagMatch = xmlMatch[i].match(tagRe);\n xml = xml.replace(\n xmlMatch[i],\n tagMatch[5]\n ? '<' + prefix + ':' + tagMatch[3] + tagMatch[4] + '>'\n : ''\n );\n }\n\n // we found matches but no namespace has been set\n if (xmlMatch.length && xml.indexOf(prefixAtt) === -1) {\n xml = xml.replace(' ({\n qtiClass: 'responseCondition',\n responseIf: {\n qtiClass: 'responseIf',\n expression: {\n qtiClass: 'match',\n expressions: [\n {\n qtiClass: 'variable',\n attributes: {\n identifier: responseIdentifier,\n },\n },\n {\n qtiClass: 'correct',\n attributes: {\n identifier: responseIdentifier,\n },\n },\n ],\n },\n responseRules: [\n {\n qtiClass: 'setOutcomeValue',\n attributes: {\n identifier: outcomeIdentifier,\n },\n expression: {\n qtiClass: 'sum',\n expressions: [\n {\n qtiClass: 'variable',\n attributes: {\n identifier: outcomeIdentifier,\n },\n },\n {\n qtiClass: 'baseValue',\n attributes: {\n baseType: 'integer'\n },\n value: '1',\n },\n ],\n },\n },\n ],\n },\n }),\n MAP_RESPONSE: (responseIdentifier, outcomeIdentifier) => ({\n qtiClass: 'responseCondition',\n responseIf: {\n qtiClass: 'responseIf',\n expression: {\n qtiClass: 'not',\n expressions: [\n {\n qtiClass: 'isNull',\n expressions: [{\n qtiClass: 'variable',\n attributes: {\n identifier: responseIdentifier,\n },\n }],\n },\n ],\n },\n responseRules: [\n {\n qtiClass: 'setOutcomeValue',\n attributes: {\n identifier: outcomeIdentifier,\n },\n expression: {\n qtiClass: 'sum',\n expressions: [\n {\n qtiClass: 'variable',\n attributes: {\n identifier: outcomeIdentifier,\n }\n },\n {\n qtiClass: 'mapResponse',\n attributes: {\n identifier: responseIdentifier,\n },\n },\n ],\n },\n },\n ],\n },\n }),\n MAP_RESPONSE_POINT: (responseIdentifier, outcomeIdentifier) => ({\n qtiClass: 'responseCondition',\n responseIf: {\n qtiClass: 'responseIf',\n expression: {\n qtiClass: 'not',\n expressions: [\n {\n qtiClass: 'isNull',\n expressions: [{\n qtiClass: 'variable',\n attributes: {\n identifier: responseIdentifier,\n },\n }],\n },\n ],\n },\n responseRules: [\n {\n qtiClass: 'setOutcomeValue',\n attributes: {\n identifier: outcomeIdentifier,\n },\n expression: {\n qtiClass: 'sum',\n expressions: [\n {\n qtiClass: 'variable',\n attributes: {\n identifier: outcomeIdentifier,\n }\n },\n {\n qtiClass: 'mapResponsePoint',\n attributes: {\n identifier: responseIdentifier,\n },\n },\n ],\n },\n },\n ],\n },\n }),\n };\n\n return responseRules;\n\n});\n\n","define('taoQtiItem/qtiItem/helper/response',['lodash', 'taoQtiItem/qtiItem/helper/responseRules'], function (_, responseRulesHelper) { 'use strict';\n\n _ = _ && Object.prototype.hasOwnProperty.call(_, 'default') ? _['default'] : _;\n responseRulesHelper = responseRulesHelper && Object.prototype.hasOwnProperty.call(responseRulesHelper, 'default') ? responseRulesHelper['default'] : responseRulesHelper;\n\n /*\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2014-2020 (original work) Open Assessment Technologies SA (under the project TAO-PRODUCT);\n *\n */\n\n const _templateNames = {\n MATCH_CORRECT: 'http://www.imsglobal.org/question/qti_v2p1/rptemplates/match_correct',\n MAP_RESPONSE: 'http://www.imsglobal.org/question/qti_v2p1/rptemplates/map_response',\n MAP_RESPONSE_POINT: 'http://www.imsglobal.org/question/qti_v2p1/rptemplates/map_response_point',\n NONE: 'no_response_processing'\n };\n\n\n var response = {\n isUsingTemplate(response, tpl) {\n if (_.isString(tpl)) {\n if (tpl === response.template || _templateNames[tpl] === response.template) {\n return true;\n }\n }\n\n return false;\n },\n isValidTemplateName(tplName) {\n return !!this.getTemplateUriFromName(tplName);\n },\n getTemplateUriFromName(tplName) {\n return _templateNames[tplName] || '';\n },\n getTemplateNameFromUri(tplUri) {\n let tplName = '';\n\n _.forIn(_templateNames, (uri, name) => {\n if (uri === tplUri) {\n tplName = name;\n return false;\n }\n });\n\n return tplName;\n },\n getTemplateNameFromResponseRules(responseIdentifier, responseRules) {\n if (!responseRules) {\n return 'NONE';\n }\n\n const {\n responseIf: {\n responseRules: [outcomeRules = {}] = [],\n } = {}\n } = responseRules;\n const {\n attributes: {\n identifier: outcomeIdentifier,\n } = {},\n } = outcomeRules;\n\n if (!outcomeIdentifier) {\n return '';\n }\n\n return Object.keys(responseRulesHelper).find(\n (key) => _.isEqual(responseRules, responseRulesHelper[key](responseIdentifier, outcomeIdentifier))\n );\n }\n };\n\n return response;\n\n});\n\n","define('taoQtiItem/qtiItem/helper/itemScore',[],function () { 'use strict';\n\n /*\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2020 (original work) Open Assessment Technologies SA (under the project TAO-PRODUCT);\n *\n */\n\n /**\n * Returns iteraction score response rule object\n *\n * @param {String} responseIdentifiers interactions reponse indentifiers\n * @returns {Obeject}\n */\n var itemScore = (responseIdentifiers) => {\n const outcomeExpressions = responseIdentifiers.map((outcomeIdentifier) => ({\n qtiClass: 'variable',\n attributes: {\n identifier: `SCORE_${outcomeIdentifier}`,\n },\n }));\n\n return {\n qtiClass: 'setOutcomeValue',\n attributes: {\n identifier: 'SCORE',\n },\n expression: {\n qtiClass: 'sum',\n expressions: outcomeExpressions,\n },\n };\n };\n\n return itemScore;\n\n});\n\n","define('taoQtiItem/qtiItem/core/Loader',['lodash', 'class', 'taoQtiItem/qtiItem/core/qtiClasses', 'taoQtiItem/qtiItem/core/Element', 'taoQtiItem/qtiItem/helper/xmlNsHandler', 'core/moduleLoader', 'taoQtiItem/qtiItem/helper/response', 'taoQtiItem/qtiItem/helper/itemScore'], function (_, _class, qtiClasses, Element, xmlNsHandler, moduleLoader, responseHelper, itemScoreHelper) { 'use strict';\n\n _ = _ && Object.prototype.hasOwnProperty.call(_, 'default') ? _['default'] : _;\n qtiClasses = qtiClasses && Object.prototype.hasOwnProperty.call(qtiClasses, 'default') ? qtiClasses['default'] : qtiClasses;\n Element = Element && Object.prototype.hasOwnProperty.call(Element, 'default') ? Element['default'] : Element;\n xmlNsHandler = xmlNsHandler && Object.prototype.hasOwnProperty.call(xmlNsHandler, 'default') ? xmlNsHandler['default'] : xmlNsHandler;\n moduleLoader = moduleLoader && Object.prototype.hasOwnProperty.call(moduleLoader, 'default') ? moduleLoader['default'] : moduleLoader;\n responseHelper = responseHelper && Object.prototype.hasOwnProperty.call(responseHelper, 'default') ? responseHelper['default'] : responseHelper;\n itemScoreHelper = itemScoreHelper && Object.prototype.hasOwnProperty.call(itemScoreHelper, 'default') ? itemScoreHelper['default'] : itemScoreHelper;\n\n /*\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2015-2020 (original work) Open Assessment Technologies SA ;\n *\n */\n\n /**\n * If a property is given as a serialized JSON object, parse it directly to a JS object\n */\n const loadPortableCustomElementProperties = (portableElement, rawProperties) => {\n var properties = {};\n\n _.forOwn(rawProperties, (value, key) => {\n try {\n properties[key] = JSON.parse(value);\n } catch (e) {\n properties[key] = value;\n }\n });\n portableElement.properties = properties;\n };\n\n const loadPortableCustomElementData = (portableElement, data) => {\n portableElement.typeIdentifier = data.typeIdentifier;\n portableElement.markup = data.markup;\n portableElement.entryPoint = data.entryPoint;\n portableElement.libraries = data.libraries;\n portableElement.setNamespace('', data.xmlns);\n\n loadPortableCustomElementProperties(portableElement, data.properties);\n };\n\n var Loader = Class.extend({\n init(item, classesLocation) {\n this.qti = {}; //loaded qti classes are store here\n this.classesLocation = {};\n this.item = item || null; //starts either from scratch or with an existing item object\n\n this.setClassesLocation(classesLocation || qtiClasses); //load default location for qti classes model\n },\n setClassesLocation(qtiClassesList) {\n _.extend(this.classesLocation, qtiClassesList);\n\n return this;\n },\n getRequiredClasses(data) {\n let ret = [];\n\n for (let i in data) {\n if (i === 'qtiClass' && data[i] !== '_container' && i !== 'rootElement') {\n //although a _container is a concrete class in TAO, it is not defined in QTI standard\n ret.push(data[i]);\n } else if (typeof data[i] === 'object' && i !== 'responseRules') {\n //responseRules should'nt be part of the parsing\n ret = _.union(ret, this.getRequiredClasses(data[i]));\n }\n }\n\n return ret;\n },\n loadRequiredClasses(data, callback, reload) {\n let requiredClass;\n const requiredClasses = this.getRequiredClasses(data, reload);\n const required = [];\n\n for (let i in requiredClasses) {\n requiredClass = requiredClasses[i];\n if (this.classesLocation[requiredClass]) {\n required.push({\n module: this.classesLocation[requiredClass],\n category: 'qti'\n });\n } else {\n throw new Error(`missing qti class location declaration : ${requiredClass}`);\n }\n }\n\n moduleLoader([], () => true).addList(required).load().then(loadeded => {\n loadeded.forEach(QtiClass => {\n this.qti[QtiClass.prototype.qtiClass] = QtiClass;\n });\n callback.call(this, this.qti);\n });\n },\n getLoadedClasses() {\n return _.keys(this.qti);\n },\n loadItemData(data, callback) {\n this.loadRequiredClasses(data, Qti => {\n if (typeof data === 'object' && data.qtiClass === 'assessmentItem') {\n //unload an item from it's serial (in case of a reload)\n if (data.serial) {\n Element.unsetElement(data.serial);\n }\n\n this.item = new Qti.assessmentItem(data.serial, data.attributes || {});\n this.loadContainer(this.item.getBody(), data.body);\n\n for (let i in data.outcomes) {\n const outcome = this.buildOutcome(data.outcomes[i]);\n\n if (outcome) {\n this.item.addOutcomeDeclaration(outcome);\n }\n }\n\n for (let i in data.feedbacks) {\n const feedback = this.buildElement(data.feedbacks[i]);\n\n if (feedback) {\n this.item.addModalFeedback(feedback);\n }\n }\n\n for (let i in data.stylesheets) {\n const stylesheet = this.buildElement(data.stylesheets[i]);\n\n if (stylesheet) {\n this.item.addStylesheet(stylesheet);\n }\n }\n\n //important : build responses after all modal feedbacks and outcomes has been loaded, because the simple feedback rules need to reference them\n let responseRules = data.responseProcessing && data.responseProcessing.responseRules\n ? [...data.responseProcessing.responseRules]\n : [];\n for (let i in data.responses) {\n const responseIdentifier = data.responses[i].identifier;\n const responseRuleItemIndex = responseRules.findIndex(({ responseIf: {\n expression: {\n expressions: [expression = {}] = [],\n } = {}\n } = {} }) => expression.attributes\n && expression.attributes.identifier === responseIdentifier\n || (\n expression.expressions\n && expression.expressions[0]\n && expression.expressions[0].attributes\n && expression.expressions[0].attributes.identifier === responseIdentifier\n )\n );\n const [responseRule] = responseRuleItemIndex !== -1\n ? responseRules.splice(responseRuleItemIndex, 1)\n : [];\n\n const response = this.buildResponse(\n data.responses[i],\n responseRule\n );\n\n if (response) {\n this.item.addResponseDeclaration(response);\n\n const feedbackRules = data.responses[i].feedbackRules;\n\n if (feedbackRules) {\n _.forIn(feedbackRules, (fbData, serial) => {\n const {\n attributes: {\n identifier: feedbackOutcomeIdentifier,\n } = {}\n } = data.outcomes[fbData.feedbackOutcome] || {};\n response.feedbackRules[serial] = this.buildSimpleFeedbackRule(fbData, response);\n\n // remove feedback response rule from response rules array\n const feedbackResponseRuleIndex = responseRules.findIndex(({\n responseIf: {\n responseRules: [setOutcomeResponseRule = {}] = [],\n } = {}\n }) => {\n const { attributes = {}, qtiClass } = setOutcomeResponseRule;\n const outcomeIdentifier = attributes.identifier;\n\n return feedbackOutcomeIdentifier === outcomeIdentifier\n && qtiClass === 'setOutcomeValue';\n });\n\n if (feedbackResponseRuleIndex !== -1) {\n responseRules.splice(feedbackResponseRuleIndex, 1);\n }\n });\n }\n }\n }\n\n const responseIdentifiers = Object.keys(this.item.responses || {})\n .map((responseKey) => this.item.responses[responseKey].attributes.identifier);\n\n if (data.responseProcessing) {\n const customResponseProcessing =\n (\n responseRules.length > 0\n && !(\n responseRules.length === 1\n && _.isEqual(\n responseRules[0],\n itemScoreHelper(\n responseIdentifiers\n )\n )\n )\n )\n || (\n this.item.responses\n && Object.keys(this.item.responses)\n .some((responseKey) => !this.item.responses[responseKey].template)\n );\n\n this.item.setResponseProcessing(this.buildResponseProcessing(data.responseProcessing, customResponseProcessing));\n }\n this.item.setNamespaces(data.namespaces);\n this.item.setSchemaLocations(data.schemaLocations);\n this.item.setApipAccessibility(data.apipAccessibility);\n }\n\n if (typeof callback === 'function') {\n callback.call(this, this.item);\n }\n });\n },\n loadAndBuildElement(data, callback) {\n this.loadRequiredClasses(data, () => {\n const element = this.buildElement(data);\n\n if (typeof callback === 'function') {\n callback.call(this, element);\n }\n });\n },\n loadElement(element, data, callback) {\n this.loadRequiredClasses(data, () => {\n this.loadElementData(element, data);\n\n if (typeof callback === 'function') {\n callback.call(this, element);\n }\n });\n },\n /**\n * Load ALL given elements into existing loaded item\n *\n * @todo to be renamed to loadItemElements\n * @param {object} data\n * @param {function} callback\n * @returns {undefined}\n */\n loadElements(data, callback) {\n if (!this.item) {\n throw new Error('QtiLoader : cannot load elements in empty item');\n }\n\n this.loadRequiredClasses(data, () => {\n const allElements = this.item.getComposingElements();\n\n for (let i in data) {\n const elementData = data[i];\n\n if (elementData && elementData.qtiClass && elementData.serial) {\n //find and update element\n if (allElements[elementData.serial]) {\n this.loadElementData(allElements[elementData.serial], elementData);\n }\n }\n }\n\n if (typeof callback === 'function') {\n callback.call(this, this.item);\n }\n });\n },\n buildResponse(data, responseRule) {\n const response = this.buildElement(data);\n\n response.template = responseHelper.getTemplateUriFromName(\n responseHelper.getTemplateNameFromResponseRules(data.identifier, responseRule)\n )\n || data.howMatch\n || null;\n\n response.defaultValue = data.defaultValue || null;\n response.correctResponse = data.correctResponses || null;\n\n if (_.size(data.mapping)) {\n response.mapEntries = data.mapping;\n } else if (_.size(data.areaMapping)) {\n response.mapEntries = data.areaMapping;\n } else {\n response.mapEntries = {};\n }\n\n response.mappingAttributes = data.mappingAttributes || {};\n\n return response;\n },\n buildSimpleFeedbackRule(data, response) {\n const feedbackRule = this.buildElement(data);\n\n feedbackRule.setCondition(response, data.condition, data.comparedValue || null);\n\n // feedbackRule.comparedOutcome = this.item.responses[data.comparedOutcome] || null;\n feedbackRule.feedbackOutcome = this.item.outcomes[data.feedbackOutcome] || null;\n feedbackRule.feedbackThen = this.item.modalFeedbacks[data.feedbackThen] || null;\n feedbackRule.feedbackElse = this.item.modalFeedbacks[data.feedbackElse] || null;\n\n //associate the compared outcome to the feedbacks if applicable\n const comparedOutcome = feedbackRule.comparedOutcome;\n\n if (feedbackRule.feedbackThen) {\n feedbackRule.feedbackThen.data('relatedResponse', comparedOutcome);\n }\n\n if (feedbackRule.feedbackElse) {\n feedbackRule.feedbackElse.data('relatedResponse', comparedOutcome);\n }\n\n return feedbackRule;\n },\n buildOutcome(data) {\n const outcome = this.buildElement(data);\n outcome.defaultValue = data.defaultValue || null;\n\n return outcome;\n },\n buildResponseProcessing(data, customResponseProcessing) {\n const rp = this.buildElement(data);\n\n if (customResponseProcessing) {\n rp.xml = data.data;\n rp.processingType = 'custom';\n } else {\n rp.processingType = 'templateDriven';\n }\n\n return rp;\n },\n loadContainer(bodyObject, bodyData) {\n if (!Element.isA(bodyObject, '_container')) {\n throw new Error('bodyObject must be a QTI Container');\n }\n\n if (!(bodyData && typeof bodyData.body === 'string' && typeof bodyData.elements === 'object')) {\n throw new Error('wrong bodydata format');\n }\n //merge attributes when loading element data\n const attributes = _.defaults(bodyData.attributes || {}, bodyObject.attributes || {});\n bodyObject.setAttributes(attributes);\n\n for (let serial in bodyData.elements) {\n const eltData = bodyData.elements[serial];\n const element = this.buildElement(eltData);\n\n //check if class is loaded:\n if (element) {\n bodyObject.setElement(element, bodyData.body);\n }\n }\n\n bodyObject.body(xmlNsHandler.stripNs(bodyData.body));\n },\n buildElement(elementData) {\n if (!(elementData && elementData.qtiClass && elementData.serial)) {\n throw new Error('wrong elementData format');\n }\n\n const className = elementData.qtiClass;\n\n if (!this.qti[className]) {\n throw new Error(`the qti element class does not exist: ${className}`);\n }\n\n const elt = new this.qti[className](elementData.serial);\n this.loadElementData(elt, elementData);\n\n return elt;\n },\n loadElementData(element, data) {\n //merge attributes when loading element data\n const attributes = _.defaults(data.attributes || {}, element.attributes || {});\n element.setAttributes(attributes);\n\n let body = data.body;\n if (!body && data.text && data.qtiClass === 'inlineChoice') {\n body = { body: data.text, elements: {} };\n }\n if (element.body && body) {\n if (element.bdy) {\n this.loadContainer(element.getBody(), body);\n }\n }\n\n if (element.object && data.object) {\n if (element.object) {\n this.loadObjectData(element.object, data.object);\n }\n }\n\n if (Element.isA(element, 'interaction')) {\n this.loadInteractionData(element, data);\n } else if (Element.isA(element, 'choice')) {\n this.loadChoiceData(element, data);\n } else if (Element.isA(element, 'math')) {\n this.loadMathData(element, data);\n } else if (Element.isA(element, 'infoControl')) {\n this.loadPicData(element, data);\n } else if (Element.isA(element, '_tooltip')) {\n this.loadTooltipData(element, data);\n }\n\n return element;\n },\n loadInteractionData(interaction, data) {\n if (Element.isA(interaction, 'blockInteraction')) {\n if (data.prompt) {\n this.loadContainer(interaction.prompt.getBody(), data.prompt);\n }\n }\n\n this.buildInteractionChoices(interaction, data);\n\n if (Element.isA(interaction, 'customInteraction')) {\n this.loadPciData(interaction, data);\n }\n },\n buildInteractionChoices(interaction, data) {\n // note: Qti.ContainerInteraction (Qti.GapMatchInteraction and Qti.HottextInteraction) has already been parsed by builtElement(interacionData);\n if (data.choices) {\n if (Element.isA(interaction, 'matchInteraction')) {\n for (let set = 0; set < 2; set++) {\n if (!data.choices[set]) {\n throw new Error(`missing match set #${set}`);\n }\n\n const matchSet = data.choices[set];\n\n for (let serial in matchSet) {\n const choice = this.buildElement(matchSet[serial]);\n\n if (choice) {\n interaction.addChoice(choice, set);\n }\n }\n }\n } else {\n for (let serial in data.choices) {\n const choice = this.buildElement(data.choices[serial]);\n\n if (choice) {\n interaction.addChoice(choice);\n }\n }\n }\n\n if (Element.isA(interaction, 'graphicGapMatchInteraction')) {\n if (data.gapImgs) {\n for (let serial in data.gapImgs) {\n const gapImg = this.buildElement(data.gapImgs[serial]);\n\n if (gapImg) {\n interaction.addGapImg(gapImg);\n }\n }\n }\n }\n }\n },\n loadChoiceData(choice, data) {\n if (Element.isA(choice, 'textVariableChoice')) {\n choice.val(data.text);\n } else if (Element.isA(choice, 'gapImg')) ; else if (Element.isA(choice, 'gapText')) {\n // this ensure compatibility of Qti 2.1 items\n if (!choice.body()) {\n choice.body(data.text);\n }\n } else if (Element.isA(choice, 'containerChoice')) ;\n },\n loadObjectData(object, data) {\n object.setAttributes(data.attributes);\n\n //@todo: manage object like a container\n if (data._alt) {\n if (data._alt.qtiClass === 'object') {\n object._alt = Loader.buildElement(data._alt);\n } else {\n object._alt = data._alt;\n }\n }\n },\n loadMathData(math, data) {\n math.ns = data.ns || {};\n math.setMathML(data.mathML || '');\n _.forIn(data.annotations || {}, (value, encoding) => {\n math.setAnnotation(encoding, value);\n });\n },\n loadTooltipData(tooltip, data) {\n tooltip.content(data.content);\n },\n loadPciData(pci, data) {\n loadPortableCustomElementData(pci, data);\n },\n loadPicData(pic, data) {\n loadPortableCustomElementData(pic, data);\n }\n });\n\n return Loader;\n\n});\n\n","define('taoQtiItem/qtiItem/helper/pci',['lodash'], function (_) { 'use strict';\n\n _ = _ && Object.prototype.hasOwnProperty.call(_, 'default') ? _['default'] : _;\n\n var pci = {\n getRawValues: function(pciVar) {\n if (_.isPlainObject(pciVar)) {\n if (pciVar.base !== undefined) {\n return _.values(pciVar.base);\n } else if (pciVar.list) {\n return _.values(pciVar.list);\n }\n }\n throw 'unsupported type ';\n }\n };\n\n return pci;\n\n});\n\n","define('taoQtiItem/qtiItem/helper/container',['lodash', 'jquery'], function (_, $) { 'use strict';\n\n _ = _ && Object.prototype.hasOwnProperty.call(_, 'default') ? _['default'] : _;\n $ = $ && Object.prototype.hasOwnProperty.call($, 'default') ? $['default'] : $;\n\n /*\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2016 (original work) Open Assessment Technologies SA\n **/\n\n /**\n * Prefix used to the variable storage\n * @type String\n */\n var _prefix = 'x-tao-';\n\n /**\n * Check if the element is of a qti container type\n *\n * @private\n * @param {Object} element\n * @returns {Boolean}\n */\n function _checkContainerType(element) {\n if (_.isFunction(element.initContainer) && _.isFunction(element.body)) {\n return true;\n } else {\n throw 'the element is not of a container type';\n }\n }\n\n /**\n * Get the body element of the container\n *\n * @private\n * @param {Object} element\n * @returns {JQuery}\n */\n function _getBodyDom(element) {\n if (_checkContainerType(element)) {\n return $('
    ')\n .html(element.body())\n .find('.x-tao-wrapper');\n }\n }\n\n /**\n * Add a class to the body element of the qti container\n *\n * @private\n * @param {Object} element\n * @param {String} newClass\n * @param {String} [oldClass]\n */\n function _setBodyDomClass(element, newClass, oldClass) {\n if (_checkContainerType(element) && (oldClass || newClass)) {\n var $wrapper = $('
    ').html(element.body());\n //set css class to element\n _setDomClass($wrapper, newClass, oldClass);\n //set to the model\n element.body($wrapper.html());\n }\n }\n\n /**\n * Switch class to the wrapped DOM\n *\n * @param {JQuery} $wrapper\n * @param {String} newClass\n * @param {String} oldClass\n * @returns {undefined}\n */\n function _setDomClass($wrapper, newClass, oldClass) {\n var $bodyDom = $wrapper.find('.x-tao-wrapper');\n if (!$bodyDom.length) {\n //create one\n $wrapper.wrapInner('
    ');\n $bodyDom = $wrapper.find('.x-tao-wrapper');\n }\n if (oldClass) {\n $bodyDom.removeClass(oldClass);\n }\n if (newClass) {\n $bodyDom.addClass(newClass);\n }\n }\n\n /**\n * Add manually the encoded information to a dom element\n *\n * @param {JQuery} $wrapper - the wrapper of the element that will holds the information\n * @param {String} dataName - the name of the information\n * @param {String} newValue - the new value to be added\n * @param {String} [oldValue] - the old value to be removed\n * @returns {undefined}\n */\n function setEncodedDataToDom($wrapper, dataName, newValue, oldValue) {\n _setDomClass($wrapper, _getEncodedDataString(dataName, newValue), _getEncodedDataString(dataName, oldValue));\n }\n\n /**\n * Get the full variable name for the data store\n *\n * @param {String} dataName\n * @param {String} value\n * @returns {String}\n */\n function _getEncodedDataString(dataName, value) {\n if (dataName && value) {\n return _prefix + dataName + '-' + value;\n }\n return '';\n }\n\n /**\n * Set a data string to the element identified by its dataName\n *\n * @param {Object} element\n * @param {String} dataName\n * @param {String} newValue\n * @returns {undefined}\n */\n function setEncodedData(element, dataName, newValue) {\n var oldValue = getEncodedData(element, dataName);\n return _setBodyDomClass(\n element,\n _getEncodedDataString(dataName, newValue),\n _getEncodedDataString(dataName, oldValue)\n );\n }\n\n /**\n * Remove the stored data from the element by its dataName\n *\n * @param {Object} element\n * @param {String} dataName\n * @returns {unresolved}\n */\n function removeEncodedData(element, dataName) {\n var oldValue = getEncodedData(element, dataName);\n if (dataName && oldValue) {\n _setBodyDomClass(element, '', _getEncodedDataString(dataName, oldValue));\n }\n }\n\n /**\n * Check if the stored data exist\n *\n * @param {Object} element\n * @param {String} dataName\n * @param {String} value\n * @returns {Boolean}\n */\n function hasEncodedData(element, dataName, value) {\n var $body = _getBodyDom(element);\n if ($body && $body.length && dataName && value) {\n return $body.hasClass(_getEncodedDataString(dataName, value));\n }\n return false;\n }\n\n /**\n * Get the encoded data identified by its dataName\n *\n * @param {Object} element\n * @param {String} dataName\n * @returns {String}\n */\n function getEncodedData(element, dataName) {\n var regex, matches;\n var $body = _getBodyDom(element);\n if (dataName && $body && $body.length && $body.attr('class')) {\n regex = new RegExp(_prefix + dataName + '-([a-zA-Z0-9-._]*)');\n matches = $body.attr('class').match(regex);\n if (matches) {\n return matches[1];\n }\n }\n }\n\n /**\n * Provide a set of helper functions to set,retirve and manage string data to a container type qti element.\n */\n var container = {\n setEncodedData: setEncodedData,\n hasEncodedData: hasEncodedData,\n getEncodedData: getEncodedData,\n removeEncodedData: removeEncodedData,\n setEncodedDataToDom: setEncodedDataToDom\n };\n\n return container;\n\n});\n\n","define('taoQtiItem/qtiRunner/modalFeedback/inlineRenderer',['lodash', 'jquery', 'context', 'taoQtiItem/qtiItem/helper/pci', 'taoQtiItem/qtiItem/helper/container', 'handlebars', 'lib/handlebars/helpers', 'iframeNotifier'], function (_, $$1, context, pci, containerHelper, Handlebars, Helpers0, iframeNotifier) { 'use strict';\n\n _ = _ && Object.prototype.hasOwnProperty.call(_, 'default') ? _['default'] : _;\n $$1 = $$1 && Object.prototype.hasOwnProperty.call($$1, 'default') ? $$1['default'] : $$1;\n context = context && Object.prototype.hasOwnProperty.call(context, 'default') ? context['default'] : context;\n pci = pci && Object.prototype.hasOwnProperty.call(pci, 'default') ? pci['default'] : pci;\n containerHelper = containerHelper && Object.prototype.hasOwnProperty.call(containerHelper, 'default') ? containerHelper['default'] : containerHelper;\n Handlebars = Handlebars && Object.prototype.hasOwnProperty.call(Handlebars, 'default') ? Handlebars['default'] : Handlebars;\n Helpers0 = Helpers0 && Object.prototype.hasOwnProperty.call(Helpers0, 'default') ? Helpers0['default'] : Helpers0;\n iframeNotifier = iframeNotifier && Object.prototype.hasOwnProperty.call(iframeNotifier, 'default') ? iframeNotifier['default'] : iframeNotifier;\n\n if (!Helpers0.__initialized) {\n Helpers0(Handlebars);\n Helpers0.__initialized = true;\n }\n var Template = Handlebars.template(function (Handlebars,depth0,helpers,partials,data) {\n this.compilerInfo = [4,'>= 1.0.0'];\n helpers = this.merge(helpers, Handlebars.helpers); data = data || {};\n var buffer = \"\", helper, options, helperMissing=helpers.helperMissing, escapeExpression=this.escapeExpression;\n\n\n buffer += \"
  • \\n \\n \"\n + escapeExpression((helper = helpers.__ || (depth0 && depth0.__),options={hash:{},data:data},helper ? helper.call(depth0, \"OK\", options) : helperMissing.call(depth0, \"__\", \"OK\", options)))\n + \"\\n \\n
  • \";\n return buffer;\n });\n function previewOkBtn(data, options, asString) {\n var html = Template(data, options);\n return (asString || true) ? html : $(html);\n }\n\n if (!Helpers0.__initialized) {\n Helpers0(Handlebars);\n Helpers0.__initialized = true;\n }\n var Template$1 = Handlebars.template(function (Handlebars,depth0,helpers,partials,data) {\n this.compilerInfo = [4,'>= 1.0.0'];\n helpers = this.merge(helpers, Handlebars.helpers); \n\n\n return \"
  • \\n \\n \\n OK\\n \\n
  • \";\n });\n function deliveryOkBtn(data, options, asString) {\n var html = Template$1(data, options);\n return (asString || true) ? html : $(html);\n }\n\n /*\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2015 (original work) Open Assessment Techonologies SA;\n *\n */\n\n var timeout = (context.timeout > 0 ? context.timeout + 1 : 30) * 1000;\n\n /**\n * Main function for the module. It loads and render the feedbacks accodring to the given itemSession variables\n *\n * @param {Object} item - the standard tao qti item object\n * @param {Object} loader - the item loader instance\n * @param {Object} renderer - the item render instance\n * @param {Object} itemSession - session information containing the list of feedbacks to display\n * @param {Function} onCloseCallback - the callback to be executed when the feedbacks are closed\n * @param {Function} [onShowCallback] - the callback to be executed when the feedbacks are shown\n * @returns {Number} Number of feedbacks to be displayed\n */\n function showFeedbacks(item, loader, renderer, itemSession, onCloseCallback, onShowCallback) {\n var interactionsDisplayInfo = getInteractionsDisplayInfo(item);\n var messages = {};\n var renderedFeebacks = [];\n var renderingQueue = [];\n var $itemContainer = item.getContainer();\n var $itemBody = $itemContainer.children('.qti-itemBody');\n var firstFeedback;\n\n _.each(item.modalFeedbacks, function(feedback) {\n var feedbackIds, message, $container, comparedOutcome, _currentMessageGroupId, interactionInfo;\n var outcomeIdentifier = feedback.attr('outcomeIdentifier');\n var order = -1;\n\n //verify if the feedback should be displayed\n if (itemSession[outcomeIdentifier]) {\n //is the feedback in the list of feedbacks to be displayed ?\n feedbackIds = pci.getRawValues(itemSession[outcomeIdentifier]);\n if (_.indexOf(feedbackIds, feedback.id()) === -1) {\n return true; //continue with next feedback\n }\n\n //which group of feedbacks (interaction related) the feedback belongs to ?\n message = getFeedbackMessageSignature(feedback);\n comparedOutcome = containerHelper.getEncodedData(feedback, 'relatedOutcome');\n interactionInfo = _.find(interactionsDisplayInfo, { responseIdentifier: comparedOutcome });\n if (comparedOutcome && interactionInfo) {\n $container = interactionInfo.displayContainer;\n _currentMessageGroupId = interactionInfo.messageGroupId;\n order = interactionInfo.order;\n } else {\n $container = $itemBody;\n _currentMessageGroupId = '__item__';\n }\n //is this message already displayed ?\n if (!messages[_currentMessageGroupId]) {\n messages[_currentMessageGroupId] = [];\n }\n if (_.indexOf(messages[_currentMessageGroupId], message) >= 0) {\n return true; //continue\n } else {\n messages[_currentMessageGroupId].push(message);\n }\n\n //ok, display feedback\n renderingQueue.push({\n feedback: feedback,\n $container: $container,\n order: order\n });\n }\n });\n\n if (renderingQueue.length) {\n renderingQueue = _.sortBy(renderingQueue, 'order');\n\n //clear previously displayed feedbacks\n clearModalFeedbacks($itemContainer);\n\n //process rendering queue\n _.each(renderingQueue, function(renderingToken) {\n renderModalFeedback(\n renderingToken.feedback,\n loader,\n renderer,\n renderingToken.$container,\n $itemContainer,\n function(renderingData) {\n // keep the first feedback to force focus on it if needed\n if (!firstFeedback) {\n firstFeedback = $$1(renderingData.dom);\n }\n\n $$1('img', renderingData.dom).on('load', function() {\n iframeNotifier.parent('itemcontentchange');\n });\n\n //record rendered feedback for later reference\n renderedFeebacks.push(renderingData);\n if (renderedFeebacks.length === renderingQueue.length) {\n //rendering processing queue completed\n iframeNotifier.parent('itemcontentchange');\n\n // set the focus on the first feedback if needed\n // TODO: this is heavily related to the old TestRunner, with the ugly iframes.\n // To make this working, a search is made accross parent frames.\n // When the InlineFeedbacks will be ported to the new TestRunner, a strong improvement will be needed!\n if (firstFeedback) {\n autoscroll(firstFeedback);\n }\n\n //if an optional \"on show modal\" callback has been provided, execute it\n if (_.isFunction(onShowCallback)) {\n onShowCallback();\n }\n }\n }\n );\n });\n\n //if any feedback is displayed, replace the controls by a \"ok\" button\n replaceControl(renderedFeebacks, $itemContainer, onCloseCallback);\n }\n\n return renderingQueue.length;\n }\n\n /**\n * Gets the QTI Container element\n * @returns {jQuery|null}\n */\n function getQtiContainer() {\n var me = window;\n var $container = null;\n var max = 10;\n\n while (me && me.__knownParent__ && max--) {\n me = me.parent;\n if (me && me.$) {\n $container = me.$('#qti-content');\n if ($container.length) {\n return $container;\n }\n }\n }\n return null;\n }\n\n /**\n * Keeps an element visible inside the QTI container.\n * If the element is outside the container viewport, scroll to display it.\n * @param {String|jQuery|HTMLElement} element\n */\n function autoscroll(element) {\n var $element = $$1(element);\n var $container = getQtiContainer();\n var currentScrollTop, minScrollTop, maxScrollTop, scrollTop;\n\n if ($element.length && $container) {\n currentScrollTop = $container.scrollTop();\n maxScrollTop = $element.offset().top;\n minScrollTop = maxScrollTop - $container.height() + $element.outerHeight();\n scrollTop = Math.max(Math.min(maxScrollTop, currentScrollTop), minScrollTop);\n if (scrollTop !== currentScrollTop) {\n $container.animate({ scrollTop: scrollTop });\n }\n }\n }\n\n /**\n * Extract the display information for an interaction-related feedback\n *\n * @private\n * @param {Object} interaction - a qti interaction object\n * @returns {Object} Object containing useful display information\n */\n function extractDisplayInfo(interaction) {\n var $interactionContainer = interaction.getContainer();\n var responseIdentifier = interaction.attr('responseIdentifier');\n var messageGroupId, $displayContainer;\n\n if (interaction.is('inlineInteraction')) {\n $displayContainer = $interactionContainer.closest('[class*=\" col-\"], [class^=\"col-\"]');\n messageGroupId = $displayContainer.attr('data-messageGroupId');\n if (!messageGroupId) {\n //generate a messageFroupId\n messageGroupId = _.uniqueId('inline_message_group_');\n $displayContainer.attr('data-messageGroupId', messageGroupId);\n }\n } else {\n messageGroupId = responseIdentifier;\n $displayContainer = $interactionContainer;\n }\n\n return {\n responseIdentifier: responseIdentifier,\n interactionContainer: $interactionContainer,\n displayContainer: $displayContainer,\n messageGroupId: messageGroupId,\n order: -1\n };\n }\n\n /**\n * Get interaction display information sorted in the order of appearance within the item\n *\n * @param {Object} item\n * @returns {Array}\n */\n function getInteractionsDisplayInfo(item) {\n var interactionsDisplayInfo = [];\n var $itemContainer = item.getContainer();\n var interactionOrder = 0;\n\n //extract all interction related information needed to display their\n _.each(item.getComposingElements(), function(element) {\n var responseIdentifier;\n if (element.is('interaction')) {\n responseIdentifier = element.attr('responseIdentifier');\n interactionsDisplayInfo.push(extractDisplayInfo(element));\n }\n });\n\n //sort interactionsDisplayInfo on the item level\n $itemContainer.find('.qti-interaction').each(function() {\n var interactionContainer = this;\n _.each(interactionsDisplayInfo, function(_interactionInfo) {\n if (_interactionInfo.interactionContainer[0] === interactionContainer) {\n _interactionInfo.order = interactionOrder;\n return false;\n }\n });\n interactionOrder++;\n });\n interactionsDisplayInfo = _.sortBy(interactionsDisplayInfo, 'order');\n\n return interactionsDisplayInfo;\n }\n\n /**\n * Remove previously displayed feedbacks contained in the given container element\n *\n * @param {JQuery} $itemContainer\n */\n function clearModalFeedbacks($itemContainer) {\n $itemContainer.find('.qti-modalFeedback').remove();\n }\n\n /**\n * Render a modal feedback into a given container, scoped within an item container\n *\n * @private\n * @param {type} feedback - feedback object\n * @param {type} loader - loader instance\n * @param {type} renderer - renderer instance\n * @param {JQuery} $container - the targeted feedback container\n * @param {JQuery} $itemContainer - the item container\n * @param {type} renderedCallback - callback when the feedback has been rendered\n * @returns {undefined}\n */\n function renderModalFeedback(feedback, loader, renderer, $container, $itemContainer, renderedCallback) {\n //load (potential) new qti classes used in the modal feedback (e.g. math, img)\n renderer.load(function() {\n //render the modal feedback\n var $modalFeedback = $$1(\n feedback.render({\n inline: true\n })\n );\n var done = function done() {\n renderedCallback({\n identifier: feedback.id(),\n serial: feedback.getSerial(),\n dom: $modalFeedback\n });\n };\n $container.append($modalFeedback);\n\n // Race between postRendering and timeout\n // postRendering waits for everything to be resolved or one reject\n Promise.race([\n Promise.all(\n _.map(feedback.getComposingElements(), function(elt) {\n //render also internal elements, such as math or img\n return elt.postRender({}, '', renderer).pop();\n })\n ),\n new Promise(function(resolve, reject) {\n _.delay(reject, timeout, new Error('Post rendering ran out of time.'));\n })\n ])\n .then(done)\n .catch(function(err) {\n //in case of postRendering issue, we are also done\n done();\n throw new Error('Error in post rendering : ' + err);\n });\n }, loader.getLoadedClasses());\n }\n\n /**\n * Replace the controls in the running environment with an \"OK\" button to trigger the end of the feedback state\n *\n * @private\n * @todo FIX ME ! replace the hack to preview and delivery toolbar with a proper plugin in the new test runner is ready\n * @param {Array} renderedFeebacks\n * @param {JQuery} $itemContainer\n * @param {Function} callback\n */\n function replaceControl(renderedFeebacks, $itemContainer, callback) {\n var $scope, $controls, $toggleContainer;\n if (window.parent && window.parent.parent && window.parent.parent.$) {\n if ($itemContainer.parents('.tao-preview-scope').length) {\n //preview mode\n $scope = window.parent.parent.$('#preview-console');\n $controls = $scope.find('.preview-console-header .action-bar li:visible');\n $toggleContainer = $scope.find('.console-button-action-bar');\n initControlToggle(renderedFeebacks, $itemContainer, $controls, $toggleContainer, previewOkBtn, callback);\n } else {\n //delivery delivery\n $scope = window.parent.parent.$('body.qti-test-scope .bottom-action-bar');\n $controls = $scope.find('li:visible');\n $toggleContainer = $scope.find('.navi-box-list');\n initControlToggle(renderedFeebacks, $itemContainer, $controls, $toggleContainer, deliveryOkBtn, callback);\n }\n } else {\n //not in an iframe, add to item body for now\n $scope = $itemContainer.find('#modalFeedbacks');\n initControlToggle(renderedFeebacks, $itemContainer, $$1(), $scope, previewOkBtn, callback);\n }\n }\n\n /**\n * Initialize the \"OK\" button to trigger the end of the feedback mode\n *\n * @private\n * @param {Array} renderedFeebacks\n * @param {JQuery} $itemContainer\n * @param {JQuery} $controls\n * @param {JQuery} $toggleContainer\n * @param {Function} toggleButtonTemplate\n * @param {Function} callback\n */\n function initControlToggle(\n renderedFeebacks,\n $itemContainer,\n $controls,\n $toggleContainer,\n toggleButtonTemplate,\n callback\n ) {\n var $ok = $$1(toggleButtonTemplate()).click(function() {\n //end feedback mode, hide feedbacks\n _.each(renderedFeebacks, function(fb) {\n fb.dom.hide();\n });\n\n //restore controls\n uncover([$itemContainer]);\n $ok.remove();\n $controls.show();\n\n //exec callback\n callback();\n });\n\n $controls.hide();\n $toggleContainer.append($ok);\n cover([$itemContainer]);\n }\n\n /**\n * Cover the given interaction containers with a transparent layer to prevent user interacting with the item\n * @private\n * @param {Array} interactionContainers\n */\n function cover(interactionContainers) {\n var $cover = $$1('
    ');\n _.each(interactionContainers, function($interaction) {\n $interaction.append($cover);\n });\n }\n\n /**\n * Remove the layer set by the function cover()\n * @private\n * @param {Array} interactionContainers\n */\n function uncover(interactionContainers) {\n _.each(interactionContainers, function($interaction) {\n $interaction.find('.interaction-cover').remove();\n });\n }\n\n /**\n * Provide the feedbackMessage signature to check if the feedback contents should be considered equals\n *\n * @param {type} feedback\n * @returns {String}\n */\n function getFeedbackMessageSignature(feedback) {\n return ('' + feedback.body() + feedback.attr('title'))\n .toLowerCase()\n .trim()\n .replace(/x-tao-[a-zA-Z0-9\\-._\\s]*/g, '');\n }\n\n var inlineRenderer = {\n showFeedbacks: showFeedbacks\n };\n\n return inlineRenderer;\n\n});\n\n","define('taoQtiItem/qtiRunner/modalFeedback/modalRenderer',['lodash', 'jquery', 'async', 'taoQtiItem/qtiItem/helper/pci'], function (_, $, async, pci) { 'use strict';\n\n _ = _ && Object.prototype.hasOwnProperty.call(_, 'default') ? _['default'] : _;\n $ = $ && Object.prototype.hasOwnProperty.call($, 'default') ? $['default'] : $;\n async = async && Object.prototype.hasOwnProperty.call(async, 'default') ? async['default'] : async;\n pci = pci && Object.prototype.hasOwnProperty.call(pci, 'default') ? pci['default'] : pci;\n\n /*\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2015 (original work) Open Assessment Techonologies SA;\n *\n */\n\n /**\n * Main function for the module. It loads and render the feedbacks accodring to the given itemSession variables\n *\n * @param {Object} item - the standard tao qti item object\n * @param {Object} loader - the item loader instance\n * @param {Object} renderer - the item render instance\n * @param {Object} itemSession - session information containing the list of feedbacks to display\n * @param {Function} onCloseCallback - the callback to be executed when the feedbacks are closed\n * @param {Function} [onShowCallback] - the callback to be executed when the feedbacks are shown\n * @returns {Number} Number of feedbacks to be displayed\n */\n function showFeedbacks(item, loader, renderer, itemSession, onCloseCallback, onShowCallback) {\n var count,\n messages = [],\n feedbacksToBeDisplayed = [];\n\n //find which modal feedbacks should be displayed according to the current item session:\n _.each(item.modalFeedbacks, function(feedback) {\n var feedbackIds, message;\n var outcomeIdentifier = feedback.attr('outcomeIdentifier');\n\n if (itemSession[outcomeIdentifier]) {\n feedbackIds = pci.getRawValues(itemSession[outcomeIdentifier]);\n message = getFeedbackMessageSignature(feedback);\n if (_.indexOf(feedbackIds, feedback.id()) >= 0 && _.indexOf(messages, message) === -1) {\n //check content if is already in the display queue\n feedbacksToBeDisplayed.push(feedback);\n messages.push(message);\n }\n }\n });\n\n //record the number of feedbacks to be displayed:\n count = feedbacksToBeDisplayed.length;\n if (count) {\n //show in reverse order\n var callstack = [];\n\n //iterate from the right because the modal popup will pile up.\n _.eachRight(feedbacksToBeDisplayed, function(feedback) {\n //the end callback should be executed to the last displayed modal, which is the last displayed one\n var endCallback;\n if (callstack.length === 0) {\n endCallback = function() {\n onCloseCallback();\n };\n }\n\n callstack.push(function(cb) {\n renderModalFeedback(\n feedback,\n loader,\n renderer,\n function() {\n cb(null);\n },\n endCallback\n );\n });\n });\n\n async.series(callstack, function() {\n //all modal are ready and displayed\n if (_.isFunction(onShowCallback)) {\n onShowCallback();\n }\n });\n }\n\n return count;\n }\n\n /**\n * Render modal feedback as a modal popup\n *\n * @param {Object} feedback - object\n * @param {Object} loader - loader instance\n * @param {Object} renderer - renderer instance\n * @param {Function} [closeCallback] - feedback to be executed when the popop closes\n * @returns {undefined}\n */\n function renderModalFeedback(feedback, loader, renderer, renderedCallback, closeCallback) {\n var $feedback,\n $feedbackBox = $('#modalFeedbacks'); //feedback.getItem().getContainer().find('#')\n\n if (feedback.is('modalFeedback')) {\n //load (potential) new qti classes used in the modal feedback (e.g. math, img)\n renderer.load(function() {\n $feedback = $feedbackBox.find('#' + feedback.getSerial());\n if (!$feedback.length) {\n //render the modal feedback\n $feedback = feedback.render();\n $feedbackBox.append($feedback);\n } else {\n $feedback.modal();\n }\n\n renderedCallback();\n\n feedback.postRender({\n callback: closeCallback\n });\n }, loader.getLoadedClasses());\n }\n }\n\n /**\n * Provide the feedbackMessage signature to check if the feedback contents should be considered equals\n *\n * @param {type} feedback\n * @returns {String}\n */\n function getFeedbackMessageSignature(feedback) {\n return ('' + feedback.body() + feedback.attr('title'))\n .toLowerCase()\n .trim()\n .replace(/x-tao-[a-zA-Z0-9\\-._\\s]*/g, '');\n }\n\n var modalRenderer = {\n showFeedbacks: showFeedbacks\n };\n\n return modalRenderer;\n\n});\n\n","define('taoQtiItem/qtiRunner/core/QtiRunner',['jquery', 'lodash', 'context', 'module', 'iframeNotifier', 'taoQtiItem/qtiItem/core/Loader', 'taoQtiItem/qtiRunner/modalFeedback/inlineRenderer', 'taoQtiItem/qtiRunner/modalFeedback/modalRenderer'], function ($, _, context, module, iframeNotifier, ItemLoader, modalFeedbackInline, modalFeedbackModal) { 'use strict';\n\n $ = $ && Object.prototype.hasOwnProperty.call($, 'default') ? $['default'] : $;\n _ = _ && Object.prototype.hasOwnProperty.call(_, 'default') ? _['default'] : _;\n context = context && Object.prototype.hasOwnProperty.call(context, 'default') ? context['default'] : context;\n module = module && Object.prototype.hasOwnProperty.call(module, 'default') ? module['default'] : module;\n iframeNotifier = iframeNotifier && Object.prototype.hasOwnProperty.call(iframeNotifier, 'default') ? iframeNotifier['default'] : iframeNotifier;\n ItemLoader = ItemLoader && Object.prototype.hasOwnProperty.call(ItemLoader, 'default') ? ItemLoader['default'] : ItemLoader;\n modalFeedbackInline = modalFeedbackInline && Object.prototype.hasOwnProperty.call(modalFeedbackInline, 'default') ? modalFeedbackInline['default'] : modalFeedbackInline;\n modalFeedbackModal = modalFeedbackModal && Object.prototype.hasOwnProperty.call(modalFeedbackModal, 'default') ? modalFeedbackModal['default'] : modalFeedbackModal;\n\n /*\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2013 (original work) Open Assessment Techonologies SA (under the project TAO-PRODUCT);\n *\n *\n */\n\n var timeout = (context.timeout > 0 ? context.timeout + 1 : 30) * 1000;\n\n var QtiRunner = function() {\n this.item = null;\n this.rpEngine = null;\n this.renderer = null;\n this.loader = null;\n this.itemApi = undefined;\n };\n\n QtiRunner.prototype.updateItemApi = function() {\n var responses = this.getResponses();\n var states = this.getStates();\n var variables = [];\n // Transform responses into state variables.\n for (var key in states) {\n var value = states[key];\n // This is where we set variables that will be collected and stored\n // as the Item State. We do not want to store large files into\n // the state, and force the client to download these files\n // all over again. We then transform them as a place holder, that will\n // simply indicate that a file composes the state.\n\n if (value.response && typeof value.response.base !== 'undefined') {\n for (var property in value.response.base) {\n if (property === 'file') {\n var file = value.response.base.file;\n // QTI File found! Replace it with an appropriate placeholder.\n // The data is base64('qti_file_datatype_placeholder_data')\n value.response = {\n base: {\n file: {\n name: file.name,\n mime: 'qti+application/octet-stream',\n data: 'cXRpX2ZpbGVfZGF0YXR5cGVfcGxhY2Vob2xkZXJfZGF0YQ=='\n }\n }\n };\n }\n }\n }\n\n variables[key] = value;\n }\n\n //set all variables at once\n this.itemApi.setVariables(variables);\n\n // Save the responses that will be used for response processing.\n this.itemApi.saveResponses(responses);\n this.itemApi.resultApi.setQtiRunner(this);\n };\n\n QtiRunner.prototype.setItemApi = function(itemApi) {\n this.itemApi = itemApi;\n var that = this;\n var oldStateVariables = JSON.stringify(itemApi.stateVariables);\n\n itemApi.onKill(function(killCallback) {\n // If the responses did not change,\n // just close gracefully.\n\n // Collect new responses and update item API.\n that.updateItemApi();\n var newStateVariables = JSON.stringify(itemApi.stateVariables);\n\n // Store the results.\n if (oldStateVariables !== newStateVariables || itemApi.serviceApi.getHasBeenPaused()) {\n itemApi.submit(function() {\n // Send successful signal.\n itemApi.serviceApi.setHasBeenPaused(false);\n killCallback(0);\n });\n } else {\n killCallback(0);\n }\n });\n };\n\n QtiRunner.prototype.setRenderer = function(renderer) {\n if (renderer.isRenderer) {\n this.renderer = renderer;\n } else {\n throw 'invalid renderer';\n }\n };\n\n QtiRunner.prototype.getLoader = function() {\n if (!this.loader) {\n this.loader = new ItemLoader();\n }\n return this.loader;\n };\n\n QtiRunner.prototype.loadItemData = function(data, callback) {\n var self = this;\n this.getLoader().loadItemData(data, function(item) {\n self.item = item;\n callback(self.item);\n });\n };\n\n QtiRunner.prototype.loadElements = function(elements, callback) {\n if (this.getLoader().item) {\n this.getLoader().loadElements(elements, callback);\n } else {\n throw 'QtiRunner : cannot load elements in empty item';\n }\n };\n\n QtiRunner.prototype.renderItem = function(data, done) {\n var self = this;\n\n done = _.isFunction(done) ? done : _.noop;\n\n var render = function() {\n if (!self.item) {\n throw 'cannot render item: empty item';\n }\n if (self.renderer) {\n self.renderer.load(function() {\n self.item.setRenderer(self.renderer);\n self.item.render({}, $('#qti_item'));\n\n // Race between postRendering and timeout\n // postRendering waits for everything to be resolved or one reject\n Promise.race([\n Promise.all(self.item.postRender()),\n new Promise(function(resolve, reject) {\n _.delay(reject, timeout, new Error('Post rendering ran out of time.'));\n })\n ])\n .then(function() {\n self.item.getContainer().on('responseChange', function(e, data) {\n if (data.interaction && data.interaction.attr('responseIdentifier') && data.response) {\n iframeNotifier.parent('responsechange', [\n data.interaction.attr('responseIdentifier'),\n data.response\n ]);\n }\n });\n\n self.initInteractionsResponse();\n self.listenForThemeChange();\n done();\n })\n .catch(function(err) {\n //in case of postRendering issue, we are also done\n done();\n\n throw new Error('Error in post rendering : ' + err);\n });\n }, self.getLoader().getLoadedClasses());\n } else {\n throw 'cannot render item: no rendered set';\n }\n };\n\n if (typeof data === 'object') {\n this.loadItemData(data, render);\n } else {\n render();\n }\n };\n\n QtiRunner.prototype.initInteractionsResponse = function() {\n var self = this;\n if (self.item) {\n var interactions = self.item.getInteractions();\n for (var i in interactions) {\n var interaction = interactions[i];\n var responseId = interaction.attr('responseIdentifier');\n self.itemApi.getVariable(responseId, function(values) {\n if (values) {\n interaction.setState(values);\n iframeNotifier.parent('stateready', [responseId, values]);\n } else {\n var states = self.getStates();\n if (_.indexOf(states, responseId)) {\n self.itemApi.setVariable(responseId, states[responseId]);\n interaction.setState(states[responseId]);\n iframeNotifier.parent('stateready', [responseId, states[responseId]]);\n }\n }\n });\n }\n }\n };\n\n /**\n * If an event 'themechange' bubbles to \"#qti_item\" node\n * then we tell the renderer to switch the theme.\n */\n QtiRunner.prototype.listenForThemeChange = function listenForThemeChange() {\n var self = this;\n var $container = this.renderer.getContainer(this.item);\n if (!$container.length) {\n $container = $('.qti-item');\n }\n $container.off('themechange').on('themechange', function(e, themeName) {\n var themeLoader = self.renderer.getThemeLoader();\n themeName = themeName || e.originalEvent.detail;\n if (themeLoader) {\n themeLoader.change(themeName);\n }\n });\n };\n\n QtiRunner.prototype.validate = function() {\n this.updateItemApi();\n this.itemApi.finish();\n };\n\n QtiRunner.prototype.getResponses = function() {\n var responses = {};\n var interactions = this.item.getInteractions();\n\n _.forEach(interactions, function(interaction) {\n var response = {};\n try {\n response = interaction.getResponse();\n } catch (e) {\n console.error(e);\n }\n responses[interaction.attr('responseIdentifier')] = response;\n });\n\n return responses;\n };\n\n QtiRunner.prototype.getStates = function() {\n var states = {};\n var interactions = this.item.getInteractions();\n\n _.forEach(interactions, function(interaction) {\n var state = {};\n try {\n state = interaction.getState();\n } catch (e) {\n console.error(e);\n }\n states[interaction.attr('responseIdentifier')] = state;\n });\n\n return states;\n };\n\n QtiRunner.prototype.setResponseProcessing = function(callback) {\n this.rpEngine = callback;\n };\n\n QtiRunner.prototype.showFeedbacks = function(itemSession, callback, onShowCallback) {\n var inlineDisplay = !!module.config().inlineModalFeedback;\n\n //currently only modal feedbacks are available\n if (inlineDisplay) {\n return modalFeedbackInline.showFeedbacks(\n this.item,\n this.getLoader(),\n this.renderer,\n itemSession,\n callback,\n onShowCallback\n );\n } else {\n return modalFeedbackModal.showFeedbacks(\n this.item,\n this.getLoader(),\n this.renderer,\n itemSession,\n callback,\n onShowCallback\n );\n }\n };\n\n return QtiRunner;\n\n});\n\n","define('taoQtiItem/qtiItem/helper/interactionHelper',['lodash', 'taoQtiItem/qtiItem/core/Element'], function (_, Element) { 'use strict';\n\n _ = _ && Object.prototype.hasOwnProperty.call(_, 'default') ? _['default'] : _;\n Element = Element && Object.prototype.hasOwnProperty.call(Element, 'default') ? Element['default'] : Element;\n\n /**\n * Common helper functions\n */\n var interactionHelper = {\n convertChoices: function(choices, outputType) {\n var ret = [],\n _this = this;\n\n _.each(choices, function(c) {\n if (Element.isA(c, 'choice')) {\n switch (outputType) {\n case 'serial':\n ret.push(c.getSerial());\n break;\n case 'identifier':\n ret.push(c.id());\n break;\n default:\n ret.push(c);\n }\n } else if (_.isArray(c)) {\n ret.push(_this.convertChoices(c, outputType));\n }\n });\n\n return ret;\n },\n findChoices: function(interaction, choices, inputType) {\n var ret = [],\n _this = this;\n\n _.each(choices, function(c) {\n var choice;\n if (_.isString(c)) {\n if (inputType === 'serial') {\n choice = interaction.getChoice(c);\n if (choice) {\n ret.push(choice);\n }\n } else if (inputType === 'identifier') {\n choice = interaction.getChoiceByIdentifier(c);\n if (choice) {\n ret.push(choice);\n }\n } else {\n ret.push(c);\n }\n } else if (_.isArray(c)) {\n ret.push(_this.findChoices(interaction, c, inputType));\n } else {\n ret.push(c);\n }\n });\n\n return ret;\n },\n shuffleChoices: function(choices) {\n var r = [], //returned array\n f = {}, //fixed choices array\n j = 0;\n\n for (var i in choices) {\n if (Element.isA(choices[i], 'choice')) {\n var choice = choices[i];\n if (choice.attr('fixed')) {\n f[j] = choice;\n }\n r.push(choice);\n j++;\n } else {\n throw 'invalid element in array: is not a qti choice';\n }\n }\n\n for (var n = 0; n < r.length - 1; n++) {\n if (f[n]) {\n continue;\n }\n var k = -1;\n do {\n k = n + Math.floor(Math.random() * (r.length - n));\n } while (f[k]);\n var tmp = r[k];\n r[k] = r[n];\n r[n] = tmp;\n }\n\n return r;\n },\n serialToIdentifier: function(interaction, choiceSerial) {\n var choice = interaction.getChoice(choiceSerial);\n if (choice) {\n return choice.id();\n } else {\n return '';\n }\n }\n };\n\n return interactionHelper;\n\n});\n\n","define('taoQtiItem/qtiRunner/core/Renderer',['lodash', 'jquery', 'taoQtiItem/qtiItem/core/Element', 'taoQtiItem/qtiItem/helper/interactionHelper', 'ui/themeLoader', 'ui/themes', 'core/moduleLoader', 'handlebars'], function (_, $, Element, interactionHelper, themeLoader, themesHelper, moduleLoader, Handlebars) { 'use strict';\n\n _ = _ && Object.prototype.hasOwnProperty.call(_, 'default') ? _['default'] : _;\n $ = $ && Object.prototype.hasOwnProperty.call($, 'default') ? $['default'] : $;\n Element = Element && Object.prototype.hasOwnProperty.call(Element, 'default') ? Element['default'] : Element;\n interactionHelper = interactionHelper && Object.prototype.hasOwnProperty.call(interactionHelper, 'default') ? interactionHelper['default'] : interactionHelper;\n themeLoader = themeLoader && Object.prototype.hasOwnProperty.call(themeLoader, 'default') ? themeLoader['default'] : themeLoader;\n themesHelper = themesHelper && Object.prototype.hasOwnProperty.call(themesHelper, 'default') ? themesHelper['default'] : themesHelper;\n moduleLoader = moduleLoader && Object.prototype.hasOwnProperty.call(moduleLoader, 'default') ? moduleLoader['default'] : moduleLoader;\n Handlebars = Handlebars && Object.prototype.hasOwnProperty.call(Handlebars, 'default') ? Handlebars['default'] : Handlebars;\n\n /*\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2014-2022 (original work) Open Assessment Technlogies SA (under the project TAO-PRODUCT);\n *\n */\n\n //webpack trick : handlebar is usale only from cjs.\n //but anyway we should deprecate the practice to invoke\n //directly Handlebars at runtimej\n let hb = Handlebars;\n if(typeof hb.compile !== 'function'){\n hb = require('handlebars');\n }\n\n const _renderableClasses = [\n '_container',\n 'assessmentItem',\n 'stylesheet',\n 'responseDeclaration',\n 'outcomeDeclaration',\n 'responseProcessing',\n '_simpleFeedbackRule',\n '_tooltip',\n 'figure',\n 'img',\n 'figcaption',\n 'math',\n 'object',\n 'table',\n 'modalFeedback',\n 'rubricBlock',\n 'associateInteraction',\n 'choiceInteraction',\n 'extendedTextInteraction',\n 'gapMatchInteraction',\n 'graphicAssociateInteraction',\n 'graphicGapMatchInteraction',\n 'graphicOrderInteraction',\n 'hotspotInteraction',\n 'hottextInteraction',\n 'inlineChoiceInteraction',\n 'matchInteraction',\n 'mediaInteraction',\n 'orderInteraction',\n 'selectPointInteraction',\n 'sliderInteraction',\n 'textEntryInteraction',\n 'uploadInteraction',\n 'endAttemptInteraction',\n 'customInteraction',\n 'prompt',\n 'associableHotspot',\n 'gap',\n 'gapImg',\n 'gapText',\n 'hotspotChoice',\n 'hottext',\n 'inlineChoice',\n 'simpleAssociableChoice',\n 'simpleChoice',\n 'infoControl',\n 'include',\n 'printedVariable'\n ];\n\n /**\n * The list of qti element dependencies. It is used internally to load dependent qti classes\n */\n const _dependencies = {\n assessmentItem: ['stylesheet', '_container', 'prompt', 'modalFeedback'],\n rubricBlock: ['_container'],\n associateInteraction: ['simpleAssociableChoice'],\n choiceInteraction: ['simpleChoice'],\n gapMatchInteraction: ['gap', 'gapText'],\n graphicAssociateInteraction: ['associableHotspot'],\n graphicGapMatchInteraction: ['associableHotspot', 'gapImg'],\n graphicOrderInteraction: ['hotspotChoice'],\n hotspotInteraction: ['hotspotChoice'],\n hottextInteraction: ['hottext'],\n inlineChoiceInteraction: ['inlineChoice'],\n matchInteraction: ['simpleAssociableChoice'],\n orderInteraction: ['simpleChoice']\n };\n\n /**\n * The list of supported qti subclasses.\n */\n const _renderableSubclasses = {\n simpleAssociableChoice: ['associateInteraction', 'matchInteraction'],\n simpleChoice: ['choiceInteraction', 'orderInteraction']\n };\n\n /**\n * List of the default properties for the item\n */\n const _defaults = {\n shuffleChoices: true\n };\n\n const _isValidRenderer = function(renderer) {\n let valid = true;\n\n if (typeof renderer !== 'object') {\n return false;\n }\n\n let classCorrect = false;\n if (renderer.qtiClass) {\n if (_.indexOf(_renderableClasses, renderer.qtiClass) >= 0) {\n classCorrect = true;\n } else {\n const pos = renderer.qtiClass.indexOf('.');\n if (pos > 0) {\n const qtiClass = renderer.qtiClass.slice(0, pos);\n const subClass = renderer.qtiClass.slice(pos + 1);\n if (_renderableSubclasses[qtiClass] && _.indexOf(_renderableSubclasses[qtiClass], subClass) >= 0) {\n classCorrect = true;\n }\n }\n }\n }\n if (!classCorrect) {\n valid = false;\n throw new Error('invalid qti class name in renderer declaration : ' + renderer.qtiClass);\n }\n\n if (!renderer.template) {\n valid = false;\n throw new Error('missing template in renderer declaration : ' + renderer.qtiClass);\n }\n\n return valid;\n };\n\n /**\n * Get the location of the document, useful to define a baseUrl for the required context\n * @returns {String}\n */\n function getDocumentBaseUrl() {\n return window.location.protocol + '//' + window.location.host + window.location.pathname.replace(/([^\\/]*)$/, '');\n }\n\n /**\n * The built Renderer class\n * @constructor\n * @param {Object} [options] - the renderer options\n * @param {AssetManager} [options.assetManager] - The renderer needs an AssetManager to resolve URLs (see {@link taoItems/assets/manager})\n * @param {Boolean} [options.shuffleChoices = true] - Does the renderer take care of the shuffling\n * @param {Object} [options.decorators] - to set up rendering decorator\n * @param {preRenderDecorator} [options.decorators.before] - to set up a pre decorator\n * @param {postRenderDecorator} [options.decorators.after] - to set up a post decorator\n */\n const Renderer = function(options) {\n /**\n * Store the registered renderer location\n */\n const _locations = {};\n\n /**\n * Store loaded renderers\n */\n const _renderers = {};\n\n options = _.defaults(options || {}, _defaults);\n\n this.isRenderer = true;\n\n this.name = '';\n\n //store shuffled choice here\n this.shuffledChoices = [];\n\n /**\n * Get the actual renderer of the give qti class or subclass:\n * e.g. simplceChoice, simpleChoice.choiceInteraction, simpleChoice.orderInteraction\n */\n const _getClassRenderer = function(qtiClass) {\n let ret = null;\n if (_renderers[qtiClass]) {\n ret = _renderers[qtiClass];\n } else {\n const pos = qtiClass.indexOf('.');\n if (pos > 0) {\n qtiClass = qtiClass.slice(0, pos);\n if (_renderers[qtiClass]) {\n ret = _renderers[qtiClass];\n }\n }\n }\n return ret;\n };\n\n /**\n * Registers a QTI renderer class\n * @param {String} qtiClass\n * @param {Array} list\n * @returns {Boolean} `true` if the class has been successfully registered\n */\n function registerRendererClass(qtiClass, list) {\n let success = false;\n if (_locations[qtiClass] === false) {\n //mark this class as not renderable\n _renderers[qtiClass] = false;\n success = true;\n } else if (_locations[qtiClass]) {\n list.push(_locations[qtiClass]);\n success = true;\n }\n return success;\n }\n\n /**\n * Set the renderer options\n * @param {String} key - the name of the option\n * @param {*} value - the option vallue\n * @returns {Renderer} for chaining\n */\n this.setOption = function(key, value) {\n if (typeof key === 'string') {\n options[key] = value;\n }\n return this;\n };\n\n /**\n * Set the renderer options\n * @param {Object} opts - the options\n * @returns {Renderer} for chaining\n */\n this.setOptions = function(opts) {\n options = _.extend(options, opts);\n return this;\n };\n\n /**\n * Get the renderer option\n * @param {String} key - the name of the option\n * @returns {*|null} the option vallue\n */\n this.getOption = function(key) {\n if (typeof key === 'string' && options[key]) {\n return options[key];\n }\n return null;\n };\n\n this.getCustomMessage = function getCustomMessage(elementName, messageKey) {\n const messages = this.getOption('messages');\n if (messages && elementName && messages[elementName] && _.isString(messages[elementName][messageKey])) {\n //currently not translatable but potentially could be if the need raises\n return hb.compile(messages[elementName][messageKey]);\n } else {\n return null;\n }\n };\n\n /**\n * Get the bound assetManager\n * @returns {AssetManager} the assetManager\n */\n this.getAssetManager = function getAssetManager() {\n return options.assetManager;\n };\n\n /**\n * Get the bound theme loader\n * @returns {Object} the themeLoader\n */\n this.getThemeLoader = function getThemeLoader() {\n return this.themeLoader;\n };\n\n /**\n * Renders the template\n * @param {Object} element - the QTI model element\n * @param {Object} data - the data to give to the template\n * @param {String} [qtiSubclass] - to get the render of the element subclass (when element's qtiClass is abstract)\n * @returns {String} the template results\n * @throws {Error} if the renderer is not set or has no template bound\n */\n this.renderTpl = function(element, data, qtiSubclass) {\n let res;\n let ret = '';\n const qtiClass = qtiSubclass || element.qtiClass;\n const renderer = _getClassRenderer(qtiClass);\n const decorators = this.getOption('decorators');\n\n if (!renderer || !_.isFunction(renderer.template)) {\n throw new Error('no renderer template loaded under the class name : ' + qtiClass);\n }\n\n //pre rendering decoration\n if (_.isObject(decorators) && _.isFunction(decorators.before)) {\n /**\n * @callback preRenderDecoractor\n * @param {Object} element - the QTI model element\n * @param {String} [qtiSubclass] - to get the render of the element subclass (when element's qtiClass is abstract)\n * @returns {String} the decorator result\n */\n res = decorators.before(element, qtiSubclass);\n if (_.isString(res)) {\n ret += res;\n }\n }\n\n //render the template\n ret += renderer.template(data);\n\n //post rendering decoration\n if (_.isObject(decorators) && _.isFunction(decorators.after)) {\n /**\n * @callback postRenderDecoractor\n * @param {Object} element - the QTI model element\n * @param {String} [qtiSubclass] - to get the render of the element subclass (when element's qtiClass is abstract)\n * @returns {String} the decorator result\n */\n res = decorators.after(element, qtiSubclass);\n if (_.isString(res)) {\n ret += res;\n }\n }\n return ret;\n };\n\n this.getData = function(element, data, qtiSubclass) {\n let ret = data;\n const qtiClass = qtiSubclass || element.qtiClass;\n const renderer = _getClassRenderer(qtiClass);\n\n if (renderer) {\n if (typeof renderer.getData === 'function') {\n ret = renderer.getData.call(this, element, data);\n }\n }\n\n return ret;\n };\n\n this.renderDirect = function(tpl, data) {\n return hb.compile(tpl)(data);\n };\n\n this.getContainer = function(qtiElement, $scope, qtiSubclass) {\n let ret = null;\n const qtiClass = qtiSubclass || qtiElement.qtiClass;\n const renderer = _getClassRenderer(qtiClass);\n\n if (renderer) {\n ret = renderer.getContainer(qtiElement, $scope);\n } else {\n throw new Error('no renderer found for the class : ' + qtiElement.qtiClass);\n }\n return ret;\n };\n\n this.postRender = function(qtiElement, data, qtiSubclass) {\n const qtiClass = qtiSubclass || qtiElement.qtiClass;\n const renderer = _getClassRenderer(qtiClass);\n\n if (renderer && typeof renderer.render === 'function') {\n return renderer.render.call(this, qtiElement, data);\n }\n };\n\n this.setResponse = function(qtiInteraction, response, qtiSubclass) {\n let ret = false;\n const qtiClass = qtiSubclass || qtiInteraction.qtiClass;\n const renderer = _getClassRenderer(qtiClass);\n\n if (renderer) {\n if (typeof renderer.setResponse === 'function') {\n ret = renderer.setResponse.call(this, qtiInteraction, response);\n const $container = renderer.getContainer.call(this, qtiInteraction);\n if ($container instanceof $ && $container.length) {\n $container.trigger('responseSet', [qtiInteraction, response]);\n }\n }\n } else {\n throw new Error('no renderer registered under the name : ' + qtiClass);\n }\n return ret;\n };\n\n this.getResponse = function(qtiInteraction, qtiSubclass) {\n let ret = false;\n const qtiClass = qtiSubclass || qtiInteraction.qtiClass;\n const renderer = _getClassRenderer(qtiClass);\n\n if (renderer) {\n if (typeof renderer.getResponse === 'function') {\n ret = renderer.getResponse.call(this, qtiInteraction);\n }\n } else {\n throw new Error('no renderer registered under the name : ' + qtiClass);\n }\n return ret;\n };\n\n this.resetResponse = function(qtiInteraction, qtiSubclass) {\n let ret = false;\n const qtiClass = qtiSubclass || qtiInteraction.qtiClass;\n const renderer = _getClassRenderer(qtiClass);\n\n if (renderer) {\n if (typeof renderer.resetResponse === 'function') {\n ret = renderer.resetResponse.call(this, qtiInteraction);\n }\n } else {\n throw new Error('no renderer registered under the name : ' + qtiClass);\n }\n return ret;\n };\n\n /**\n * Retrieve the state of the interaction.\n * If the renderer has no state management, it falls back to the response management.\n *\n * @param {Object} qtiInteraction - the interaction\n * @param {String} [qtiSubClass] - (not sure of the type and how it is used - Sam ? )\n * @returns {Object} the interaction's state\n *\n * @throws {Error} if no renderer is registered\n */\n this.getState = function(qtiInteraction, qtiSubclass) {\n let ret = false;\n const qtiClass = qtiSubclass || qtiInteraction.qtiClass;\n const renderer = _getClassRenderer(qtiClass);\n\n if (renderer) {\n if (_.isFunction(renderer.getState)) {\n ret = renderer.getState.call(this, qtiInteraction);\n } else {\n ret = renderer.getResponse.call(this, qtiInteraction);\n }\n } else {\n throw new Error('no renderer registered under the name : ' + qtiClass);\n }\n return ret;\n };\n\n /**\n * Retrieve the state of the interaction.\n * If the renderer has no state management, it falls back to the response management.\n *\n * @param {Object} qtiInteraction - the interaction\n * @param {Object} state - the interaction's state\n * @param {String} [qtiSubClass] - (not sure of the type and how it is used - Sam ? )\n *\n * @throws {Error} if no renderer is found\n */\n this.setState = function(qtiInteraction, state, qtiSubclass) {\n const qtiClass = qtiSubclass || qtiInteraction.qtiClass;\n const renderer = _getClassRenderer(qtiClass);\n\n if (renderer) {\n if (_.isFunction(renderer.setState)) {\n renderer.setState.call(this, qtiInteraction, state);\n } else {\n renderer.resetResponse.call(this, qtiInteraction);\n renderer.setResponse.call(this, qtiInteraction, state);\n }\n } else {\n throw new Error('no renderer registered under the name : ' + qtiClass);\n }\n };\n\n /**\n * Calls the renderer destroy.\n * Ask the renderer to run destroy if exists.\n *\n * @throws {Error} if no renderer is found\n */\n this.destroy = function(qtiInteraction, qtiSubclass) {\n let ret = false;\n const qtiClass = qtiSubclass || qtiInteraction.qtiClass;\n const renderer = _getClassRenderer(qtiClass);\n\n if (renderer) {\n if (_.isFunction(renderer.destroy)) {\n ret = renderer.destroy.call(this, qtiInteraction);\n }\n } else {\n throw new Error('no renderer registered under the name : ' + qtiClass);\n }\n return ret;\n };\n\n this.getLoadedRenderers = function() {\n return _renderers;\n };\n\n this.register = function(renderersLocations) {\n _.extend(_locations, renderersLocations);\n };\n\n this.load = function(callback, requiredClasses) {\n const self = this;\n let required = [];\n\n const themeData = themesHelper.getCurrentThemeData();\n if (themeData) {\n options.themes = themeData;\n }\n if (options.themes) {\n //resolve themes paths\n options.themes.base = this.resolveUrl(options.themes.base);\n _.forEach(options.themes.available, function(theme, index) {\n options.themes.available[index].path = self.resolveUrl(theme.path);\n });\n this.themeLoader = themeLoader(options.themes).load(options.preload);\n }\n\n if (requiredClasses) {\n if (_.isArray(requiredClasses)) {\n //exclude abstract classes\n requiredClasses = _.intersection(requiredClasses, _renderableClasses);\n\n //add dependencies\n _.each(requiredClasses, function(reqClass) {\n const deps = _dependencies[reqClass];\n if (deps) {\n requiredClasses = _.union(requiredClasses, deps);\n }\n });\n\n _.forEach(requiredClasses, function(qtiClass) {\n let requiredSubClasses;\n if (_renderableSubclasses[qtiClass]) {\n requiredSubClasses = _.intersection(requiredClasses, _renderableSubclasses[qtiClass]);\n _.each(requiredSubClasses, function(subclass) {\n if (\n !registerRendererClass(qtiClass + '.' + subclass, required) &&\n !registerRendererClass(qtiClass, required)\n ) {\n throw new Error(\n self.name +\n ' : missing qti class location declaration: ' +\n qtiClass +\n ', subclass: ' +\n subclass\n );\n }\n });\n } else {\n if (!registerRendererClass(qtiClass, required)) {\n throw new Error(self.name + ' : missing qti class location declaration: ' + qtiClass);\n }\n }\n });\n } else {\n throw new Error('invalid argument type: expected array for arg \"requireClasses\"');\n }\n } else {\n required = _.values(_locations);\n }\n\n moduleLoader([], ()=> true)\n .addList( required.map( module => ({ module, category: 'qti'}) ) )\n .load()\n .then( loaded => {\n loaded.forEach( clazz => {\n if (_isValidRenderer(clazz)) {\n _renderers[clazz.qtiClass] = clazz;\n }\n\n });\n if (typeof callback === 'function') {\n callback.call(self, _renderers);\n }\n });\n\n return this;\n };\n\n /**\n * Unload the renderer\n */\n this.unload = function unload() {\n if (this.themeLoader) {\n themeLoader(options.themes).unload();\n }\n return this;\n };\n\n /**\n * Define the shuffling manually\n *\n * @param {Object} interaction - the interaction\n * @param {Array} choices - the shuffled choices\n * @param {String} identificationType -\n */\n this.setShuffledChoices = function(interaction, choices, identificationType) {\n if (Element.isA(interaction, 'interaction')) {\n this.shuffledChoices[interaction.getSerial()] = _.pluck(\n interactionHelper.findChoices(interaction, choices, identificationType),\n 'serial'\n );\n }\n };\n\n /**\n * Get the choices shuffled for this interaction.\n *\n * @param {Object} interaction - the interaction\n * @param {Boolean} reshuffle - by default choices are shuffled only once and store, but if true you can force shuffling again\n * @param {String} returnedType - the choice type\n * @returns {Array} the choices\n */\n this.getShuffledChoices = function(interaction, reshuffle, returnedType) {\n let choices = [];\n let serial, i;\n\n if (Element.isA(interaction, 'interaction')) {\n serial = interaction.getSerial();\n\n //1st time, we shuffle (or asked to force shuffling)\n if (!this.shuffledChoices[serial] || reshuffle) {\n if (Element.isA(interaction, 'matchInteraction')) {\n this.shuffledChoices[serial] = [];\n for (i = 0; i < 2; i++) {\n choices[i] = interactionHelper.shuffleChoices(interaction.getChoices(i));\n this.shuffledChoices[serial][i] = _.pluck(choices[i], 'serial');\n }\n } else {\n choices = interactionHelper.shuffleChoices(interaction.getChoices());\n this.shuffledChoices[serial] = _.pluck(choices, 'serial');\n }\n\n //otherwise get the choices from the serials\n } else {\n if (Element.isA(interaction, 'matchInteraction')) {\n _.forEach(choices, function(choice, index) {\n if (index < 2) {\n _.forEach(this.shuffledChoices[serial][i], function(choiceSerial) {\n choice.push(interaction.getChoice(choiceSerial));\n });\n }\n });\n } else {\n _.forEach(this.shuffledChoices[serial], function(choiceSerial) {\n choices.push(interaction.getChoice(choiceSerial));\n });\n }\n }\n\n //do some type convertion\n if (returnedType === 'serial' || returnedType === 'identifier') {\n return interactionHelper.convertChoices(choices, returnedType);\n }\n\n //pass value only, not ref\n return _.clone(choices);\n }\n\n return [];\n };\n\n this.getRenderers = function() {\n return _renderers;\n };\n\n this.getLocations = function() {\n return _locations;\n };\n\n /**\n * Resolve URLs using the defined assetManager's strategies\n * @param {String} url - the URL to resolve\n * @returns {String} the resolved URL\n */\n this.resolveUrl = function resolveUrl(url) {\n if (!options.assetManager) {\n return url;\n }\n if (typeof url === 'string' && url.length > 0) {\n return options.assetManager.resolve(url);\n }\n };\n\n /**\n * @deprecated in favor of resolveUrl\n */\n this.getAbsoluteUrl = function(relUrl) {\n //let until method is removed\n console.warn('DEPRECATED used getAbsoluteUrl with ', arguments);\n\n //allow relative url output only if explicitely said so\n if (this.getOption('userRelativeUrl')) {\n return relUrl.replace(/^\\.?\\//, '');\n }\n\n if (/^http(s)?:\\/\\//i.test(relUrl) || /^data:[^\\/]+\\/[^;]+(;charset=[\\w]+)?;base64,/.test(relUrl)) {\n //already absolute or base64 encoded\n return relUrl;\n } else {\n let absUrl = '';\n const runtimeLocations = this.getOption('runtimeLocations');\n\n if (runtimeLocations && _.size(runtimeLocations)) {\n _.forIn(runtimeLocations, function(runtimeLocation, typeIdentifier) {\n if (relUrl.indexOf(typeIdentifier) === 0) {\n absUrl = relUrl.replace(typeIdentifier, runtimeLocation);\n return false; //break\n }\n });\n }\n\n if (absUrl) {\n return absUrl;\n } else {\n const baseUrl = this.getOption('baseUrl') || getDocumentBaseUrl();\n return baseUrl + relUrl;\n }\n }\n };\n\n this.setAreaBroker = function setAreaBroker(areaBroker) {\n this._areaBroker = areaBroker;\n };\n\n this.getAreaBroker = function getAreaBroker() {\n if (this._areaBroker) {\n return this._areaBroker;\n }\n };\n\n this.getItemCreator = function getItemCreator() {\n return this.getOption('itemCreator');\n };\n };\n\n /**\n * Expose the renderer's factory\n * @exports taoQtiItem/qtiRunner/core/Renderer\n */\n var Renderer$1 = {\n /**\n * Creates a new Renderer by extending the Renderer's prototype\n * @param {Object} renderersLocations -\n * @param {String} [name] - the new renderer name\n * @param {Object} [defaultOptions] - the renderer options\n */\n build: function(renderersLocations, name, defaultOptions) {\n const NewRenderer = function() {\n const options = _.isPlainObject(arguments[0]) ? arguments[0] : {};\n\n Renderer.apply(this);\n\n this.register(renderersLocations);\n this.name = name || '';\n this.setOptions(_.defaults(options, defaultOptions || {}));\n };\n NewRenderer.prototype = Renderer.prototype;\n return NewRenderer;\n }\n };\n\n return Renderer$1;\n\n});\n\n","/*\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2016 (original work) Open Assessment Technologies SA;\n *\n */\ndefine('taoQtiItem/portableElementRegistry/factory/factory',['lodash', 'core/promise', 'core/eventifier'], function (_, Promise, eventifier){\n 'use strict';\n\n var _requirejs = window.require;\n var _defaultLoadingOptions = {\n reload: false\n };\n\n var loadModuleConfig = function loadModuleConfig(manifest){\n return new Promise(function(resolve, reject){\n var requireConfigAliases = {};\n var baseUrl;\n var reqConfigs = [];\n var modules = {};\n\n if(!manifest || !manifest.runtime){\n return reject('invalid manifest');\n }\n\n baseUrl = manifest.baseUrl;\n\n if(_.isArray(manifest.runtime.config) && manifest.runtime.config.length){\n _.forEach(manifest.runtime.config, function(pciConfig){\n if(_.isString(pciConfig)){\n reqConfigs.push('json!' + baseUrl + '/' + pciConfig);\n }else{\n if(pciConfig.data){\n modules = _.defaults(modules, pciConfig.data.paths || {});\n }else if(pciConfig.file){\n reqConfigs.push('json!' + baseUrl + '/' + pciConfig.file);\n }\n }\n });\n }\n\n require(reqConfigs, function(){\n\n var runtimeModules = {};\n\n requireConfigAliases[manifest.typeIdentifier] = baseUrl;\n\n if(manifest.model === 'IMSPCI'){\n\n modules = _.reduce(arguments, function(acc, conf){\n return _.defaults(acc, conf.paths || {});\n }, modules);\n\n _.forEach(manifest.runtime.modules || {}, function(paths, id){\n if(paths && (_.isString(paths) || (_.isArray(paths) && paths.length))){\n runtimeModules[id] = paths;\n }\n });\n\n modules = _.merge(modules, runtimeModules);\n\n _.forEach(modules, function(paths, id){\n paths = _.isArray(paths) ? paths : [paths];\n requireConfigAliases[id] = _.map(paths, function(path){\n return baseUrl+'/'+path.replace(/\\.js$/, '');\n });\n });\n }\n\n resolve(requireConfigAliases);\n\n }, reject);\n\n\n });\n };\n\n /**\n * Evaluate if the given object is a proper portable element provider\n * @param {Object} provider\n * @returns {Boolean}\n */\n var isPortableElementProvider = function isPortableElementProvider(provider){\n return (provider && _.isFunction(provider.load));\n };\n\n return function portableElementRegistry(methods){\n\n var _loaded = false;\n var __providers = {};\n\n /**\n * The portable element registry instance\n * @typedef {portableElementRegistry}\n */\n return eventifier(_.defaults(methods || {}, {\n _registry : {},\n\n /**\n * Get a register portable element\n * @param {String} typeIdentifier\n * @param {String} version\n * @returns {Object}\n */\n get : function get(typeIdentifier, version){\n\n if(this._registry[typeIdentifier]){\n //check version\n if(version){\n return _.find(this._registry[typeIdentifier], {version : version});\n }else{\n //latest\n return _.last(this._registry[typeIdentifier]);\n }\n }\n },\n\n /**\n * Register a portable element provider\n * @param moduleName\n * @param {String|Object }provider - the portable provider object or module name\n * @returns {portableElementRegistry}\n */\n registerProvider : function registerProvider(moduleName, provider){\n __providers[moduleName] = isPortableElementProvider(provider) ? provider : null;\n _loaded = false;\n return this;\n },\n\n /**\n * Clear all previously registered providers\n * @returns {portableElementRegistry}\n */\n resetProviders : function resetProviders(){\n __providers = {};\n _loaded = false;\n return this;\n },\n\n /**\n * Load the providers\n * @param {Object} [options]\n * @param {Boolean} [options.reload] - force to reload the registered providers\n * @returns {Promise}\n */\n loadProviders : function loadProviders(options){\n var self = this;\n var loadPromise;\n\n if(_loaded && !options.reload){\n loadPromise = Promise.resolve([]);\n } else {\n loadPromise = new Promise(function(resolve, reject) {\n var providerLoadingStack = [];\n _.forIn(__providers, function(provider, id){\n if(provider === null){\n providerLoadingStack.push(id);\n }\n });\n _requirejs(providerLoadingStack, function(){\n _.each([].slice.call(arguments), function(provider){\n if(isPortableElementProvider(provider)){\n __providers[providerLoadingStack.shift()] = provider;\n }\n });\n resolve(__providers);\n _loaded = true;\n self.trigger('providersloaded', __providers);\n }, reject);\n });\n }\n\n return loadPromise;\n },\n\n /**\n * Get all versions of all portable elements registered\n * @returns {Object} - all portable elements and their versions\n */\n getAllVersions : function getAllVersions(){\n var all = {};\n _.forIn(this._registry, function (versions, id){\n all[id] = _.map(versions, 'version');\n });\n return all;\n },\n\n /**\n * Get the runtime for a given portable element\n * @param {String} typeIdentifier\n * @param {String} [version] - if the version is provided, the method will try to find that version\n * @returns {Object} the runtime model\n */\n getRuntime : function getRuntime(typeIdentifier, version){\n var portableElement = this.get(typeIdentifier, version);\n if(portableElement){\n return _.assign(portableElement.runtime, {\n id : portableElement.typeIdentifier,\n label : portableElement.label,\n baseUrl : portableElement.baseUrl,\n model : portableElement.model\n });\n }else{\n this.trigger('error', {\n message : 'no portable element runtime found',\n typeIdentifier : typeIdentifier,\n version : version\n });\n }\n },\n\n /**\n * Get the creator model for a given portable element\n * @param {String} typeIdentifier\n * @param {String} [version] - if the version is provided, the method will try to find that version\n * @returns {Object} the creator model\n */\n getCreator : function getCreator(typeIdentifier, version){\n var portableElement = this.get(typeIdentifier, version);\n if(portableElement && portableElement.creator){\n return _.assign(portableElement.creator, {\n id : portableElement.typeIdentifier,\n label : portableElement.label,\n baseUrl : portableElement.baseUrl,\n response : portableElement.response,\n model : portableElement.model,\n xmlns : portableElement.xmlns\n });\n }else{\n this.trigger('error', {\n message : 'no portable element runtime found',\n typeIdentifier : typeIdentifier,\n version : version\n });\n }\n },\n\n /**\n * Returned all enabled created from the registry\n * @returns {Object} the collection of creators\n */\n getLatestCreators : function getLatestCreators(){\n var all = {};\n _.forIn(this._registry, function (versions, id){\n var lastVersion = _.last(versions);\n\n //check if the portable element is creatable:\n if(lastVersion.creator && lastVersion.creator.hook && lastVersion.enabled){\n all[id] = lastVersion;\n }\n });\n return all;\n },\n\n /**\n * Get the baseUrl for a given portable element\n * @param {String} typeIdentifier\n * @param {String} [version] - if the version is provided, the method will try to find that version\n * @returns {String} the base url\n */\n getBaseUrl : function getBaseUrl(typeIdentifier, version){\n var runtime = this.get(typeIdentifier, version);\n if(runtime){\n return runtime.baseUrl;\n }\n return '';\n },\n\n /**\n * Load the runtimes from registered portable element provider(s)\n *\n * @param {Object} [options]\n * @param {Array} [options.include] - the exact list of portable element typeIdentifier that should be loaded\n * @param {Boolean} [options.reload] - tells if all interactions should be reloaded\n * @returns {Promise}\n */\n loadRuntimes : function loadRuntimes(options){\n var self = this;\n var loadPromise;\n\n options = _.defaults(options||{}, _defaultLoadingOptions);\n\n loadPromise = self.loadProviders(options).then(function(providers){\n\n var loadStack = [];\n\n _.forEach(providers, function (provider){\n if(provider){//check that the provider is loaded\n loadStack.push(provider.load());\n }\n });\n\n //performs the loadings in parallel\n return Promise.all(loadStack).then(function (results){//TODO could remove one level of promise\n\n var configLoadingStack = [];\n\n //update registry\n self._registry = _.reduce(results, function (acc, _pcis){\n return _.merge(acc, _pcis);\n }, self._registry || {});//incremental loading\n\n //pre-configuring the baseUrl of the portable element's source\n _.forIn(self._registry, function (versions, typeIdentifier){\n if(_.isArray(options.include) && _.indexOf(options.include, typeIdentifier) < 0){\n return true;\n }\n configLoadingStack.push(loadModuleConfig(self.get(typeIdentifier)));\n });\n\n return Promise.all(configLoadingStack).then(function(moduleConfigs){\n var requireConfigAliases = _.reduce(moduleConfigs, function(acc, paths){\n return _.merge(acc, paths);\n }, {});\n\n //save the required libs name => path to global require alias\n //TODO in future planned user story : change this to a local require context to solve conflicts in third party module naming\n _requirejs.config({paths : requireConfigAliases});\n });\n });\n\n });\n\n\n loadPromise\n .then(function() {\n self.trigger('runtimesloaded');\n })\n .catch(function(err) {\n self.trigger('error', err);\n });\n\n return loadPromise;\n },\n\n /**\n * Load the creators from registered portable element provider(s)\n *\n * @param {Object} [options]\n * @param {Array} [options.include] - the exact list of portable element typeIdentifier that should be loaded\n * @param {Boolean} [options.reload] - tells if all interactions should be reloaded\n * @returns {Promise}\n */\n loadCreators : function loadCreators(options){\n var loadPromise;\n var self = this;\n\n options = _.defaults(options||{}, _defaultLoadingOptions);\n\n loadPromise = self.loadRuntimes(options).then(function(){\n var requiredCreatorHooks = [];\n\n _.forIn(self._registry, function (versions, typeIdentifier){\n var portableElementModel = self.get(typeIdentifier);//currently use the latest version only\n if(portableElementModel.creator && portableElementModel.creator.hook){\n if(portableElementModel.enabled){\n if(_.isArray(options.include) && _.indexOf(options.include, typeIdentifier) < 0){\n return true;\n }\n }else{\n if(!_.isArray(options.include) || _.indexOf(options.include, typeIdentifier) < 0){\n return true;\n }\n }\n requiredCreatorHooks.push(portableElementModel.creator.hook.replace(/\\.js$/, ''));\n }\n });\n\n if(requiredCreatorHooks.length){\n return new Promise(function(resolve, reject){\n //@todo support caching?\n _requirejs(requiredCreatorHooks, function (){\n var creators = {};\n _.each(arguments, function (creatorHook){\n var id = creatorHook.getTypeIdentifier();\n var portableElementModel = self.get(id);\n var i = _.findIndex(self._registry[id], {version : portableElementModel.version});\n if(i < 0){\n self.trigger('error', 'no creator found for id/version ' + id + '/' + portableElementModel.version);\n }else{\n self._registry[id][i].creator.module = creatorHook;\n creators[id] = creatorHook;\n }\n });\n resolve(creators);\n }, reject);\n });\n }else{\n return Promise.resolve({});\n }\n\n });\n\n loadPromise\n .then(function(creators) {\n self.trigger('creatorsloaded', creators);\n return creators;\n })\n .catch(function(err) {\n self.trigger('error', err);\n });\n\n return loadPromise;\n },\n\n /**\n * enable a portable element\n * @param {String} typeIdentifier\n * @param {String} [version] - if the version is provided, the method will try to find that version\n * @returns {portableElementRegistry}\n */\n enable: function enable(typeIdentifier, version){\n var portableElement = this.get(typeIdentifier, version);\n if(portableElement){\n portableElement.enabled = true;\n }\n return this;\n },\n\n /**\n * disable a portable element\n * @param {String} typeIdentifier\n * @param {String} [version] - if the version is provided, the method will try to find that version\n * @returns {portableElementRegistry}\n */\n disable: function disable(typeIdentifier, version){\n var portableElement = this.get(typeIdentifier, version);\n if(portableElement){\n portableElement.enabled = false;\n }\n return this;\n },\n\n /**\n * check is a portable element is enabled\n * @param {String} typeIdentifier\n * @param {String} [version] - if the version is provided, the method will try to find that version\n * @returns {portableElementRegistry}\n */\n isEnabled: function isEnabled(typeIdentifier, version){\n var portableElement = this.get(typeIdentifier, version);\n return (portableElement && portableElement.enabled === true);\n }\n }));\n };\n});\n","/**\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2015-2022 (original work) Open Assessment Technologies SA ;\n */\n/**\n * Utility to retrieve and manipualte QTI Elements\n */\ndefine('taoQtiItem/qtiCreator/helper/qtiElements',['jquery', 'lodash', 'i18n', 'services/features'], function ($, _, __, featuresService) {\n 'use strict';\n\n const QtiElements = {\n classes: {\n //abstract classes:\n itemBody: { parents: ['bodyElement'], contains: ['block'], abstract: true },\n atomicBlock: {\n parents: ['blockStatic', 'bodyElement', 'flowStatic'],\n contains: ['inline'],\n abstract: true\n },\n atomicInline: {\n parents: ['bodyElement', 'flowStatic', 'inlineStatic'],\n contains: ['inline'],\n abstract: true\n },\n simpleBlock: { parents: ['blockStatic', 'bodyElement', 'flowStatic'], contains: ['block'], abstract: true },\n simpleInline: {\n parents: ['bodyElement', 'flowStatic', 'inlineStatic'],\n contains: ['inline'],\n abstract: true\n },\n flowStatic: { parents: ['flow'], abstract: true },\n blockStatic: { parents: ['block'], abstract: true },\n inlineStatic: { parents: ['inline'], abstract: true },\n flow: { parents: ['objectFlow'], abstract: true },\n tableCell: { parents: ['bodyElement'], contains: ['flow'], abstract: true },\n //html-derived qti elements:\n caption: { parents: ['bodyElement'], contains: ['inline'], xhtml: true },\n col: { parents: ['bodyElement'], xhtml: true },\n colgroup: { parents: ['bodyElement'], contains: ['col'], xhtml: true },\n div: { parents: ['blockStatic', 'bodyElement', 'flowStatic'], contains: ['flow'], xhtml: true },\n dl: { parents: ['blockStatic', 'bodyElement', 'flowStatic'], contains: ['dlElement'], xhtml: true },\n dt: { parents: ['dlElement'], contains: ['inline'], xhtml: true },\n dd: { parents: ['dlElement'], contains: ['flow'], xhtml: true },\n hr: { parents: ['blockStatic', 'bodyElement', 'flowStatic'], xhtml: true },\n math: { parents: ['blockStatic', 'flowStatic', 'inlineStatic'], xhtml: true },\n li: { parents: ['bodyElement'], contains: ['flow'], xhtml: true },\n ol: { parents: ['blockStatic', 'bodyElement', 'flowStatic'], contains: ['li'], xhtml: true },\n ul: { parents: ['blockStatic', 'bodyElement', 'flowStatic'], contains: ['li'], xhtml: true },\n object: { parents: ['bodyElement', 'flowStatic', 'inlineStatic'], contains: ['objectFlow'], xhtml: true },\n param: { parents: ['objectFlow'], xhtml: true },\n table: {\n parents: ['blockStatic', 'bodyElement', 'flowStatic'],\n contains: ['caption', 'col', 'colgroup', 'thead', 'tfoot', 'tbody'],\n xhtml: true\n },\n tbody: { parents: ['bodyElement'], contains: ['tr'], xhtml: true },\n tfoot: { parents: ['bodyElement'], contains: ['tr'], xhtml: true },\n thead: { parents: ['bodyElement'], contains: ['tr'], xhtml: true },\n td: { parents: ['tableCell'], xhtml: true },\n th: { parents: ['tableCell'], xhtml: true },\n tr: { parents: ['bodyElement'], contains: ['tableCell'], xhtml: true },\n a: { parents: ['simpleInline'], xhtml: true },\n abbr: { parents: ['simpleInline'], xhtml: true },\n acronym: { parents: ['simpleInline'], xhtml: true },\n b: { parents: ['simpleInline'], xhtml: true },\n big: { parents: ['simpleInline'], xhtml: true },\n cite: { parents: ['simpleInline'], xhtml: true },\n code: { parents: ['simpleInline'], xhtml: true },\n dfn: { parents: ['simpleInline'], xhtml: true },\n em: { parents: ['simpleInline'], xhtml: true },\n i: { parents: ['simpleInline'], xhtml: true },\n kbd: { parents: ['simpleInline'], xhtml: true },\n q: { parents: ['simpleInline'], xhtml: true },\n samp: { parents: ['simpleInline'], xhtml: true },\n small: { parents: ['simpleInline'], xhtml: true },\n span: { parents: ['simpleInline'], xhtml: true },\n strong: { parents: ['simpleInline'], xhtml: true },\n sub: { parents: ['simpleInline'], xhtml: true },\n sup: { parents: ['simpleInline'], xhtml: true },\n tt: { parents: ['simpleInline'], xhtml: true },\n var: { parents: ['simpleInline'], xhtml: true },\n blockquote: { parents: ['simpleBlock'], xhtml: true },\n address: { parents: ['atomicBlock'], xhtml: true },\n h1: { parents: ['atomicBlock'], xhtml: true },\n h2: { parents: ['atomicBlock'], xhtml: true },\n h3: { parents: ['atomicBlock'], xhtml: true },\n h4: { parents: ['atomicBlock'], xhtml: true },\n h5: { parents: ['atomicBlock'], xhtml: true },\n h6: { parents: ['atomicBlock'], xhtml: true },\n p: { parents: ['atomicBlock'], xhtml: true },\n pre: { parents: ['atomicBlock'], xhtml: true },\n img: { parents: ['atomicInline'], xhtml: true, attributes: ['src', 'alt', 'longdesc', 'height', 'width'] },\n br: { parents: ['atomicInline'], xhtml: true },\n //qti elements:\n infoControl: { parents: ['blockStatic', 'bodyElement', 'flowStatic'], qti: true },\n textRun: { parents: ['inlineStatic', 'flowstatic'], qti: true },\n feedbackInline: { parents: ['simpleInline', 'feedbackElement'], qti: true },\n feedbackBlock: { parents: ['simpleBlock'], qti: true },\n rubricBlock: { parents: ['simpleBlock'], qti: true }, //strange qti 2.1 exception, marked as simpleBlock instead of\n blockInteraction: { parents: ['block', 'flow', 'interaction'], qti: true },\n inlineInteraction: { parents: ['inline', 'flow', 'interaction'], qti: true },\n gap: { parents: ['inlineStatic'], qti: true },\n hottext: { parents: ['flowstatic', 'inlineStatic'], contains: ['inlineStatic'], qti: true },\n printedVariable: { parents: ['bodyElement', 'flowStatic', 'inlineStatic', 'textOrVariable'], qti: true },\n prompt: { parents: ['bodyElement'], contains: ['inlineStatic'], qti: true },\n templateElement: { parents: ['bodyElement'], qti: true },\n templateBlock: {\n parents: ['blockStatic', 'flowStatic', 'templateElement'],\n contains: ['blockStatic'],\n qti: true\n },\n templateInline: {\n parents: ['inlineStatic', 'flowStatic', 'templateElement'],\n contains: ['inlineStatic'],\n qti: true\n },\n choiceInteraction: { parents: ['blockInteraction'], qti: true },\n associateInteraction: { parents: ['blockInteraction'], qti: true },\n orderInteraction: { parents: ['blockInteraction'], qti: true },\n matchInteraction: { parents: ['blockInteraction'], qti: true },\n hottextInteraction: { parents: ['blockInteraction'], qti: true },\n gapMatchInteraction: { parents: ['blockInteraction'], qti: true },\n mediaInteraction: { parents: ['blockInteraction'], qti: true },\n sliderInteraction: { parents: ['blockInteraction'], qti: true },\n uploadInteraction: { parents: ['blockInteraction'], qti: true },\n drawingInteraction: { parents: ['blockInteraction'], qti: true },\n graphicInteraction: { parents: ['blockInteraction'], qti: true },\n hotspotInteraction: { parents: ['graphicInteraction'], qti: true },\n graphicAssociateInteraction: { parents: ['graphicInteraction'], qti: true },\n graphicOrderInteraction: { parents: ['graphicInteraction'], qti: true },\n graphicGapMatchInteraction: { parents: ['graphicInteraction'], qti: true },\n selectPointInteraction: { parents: ['graphicInteraction'], qti: true },\n textEntryInteraction: { parents: ['stringInteraction', 'inlineInteraction'], qti: true },\n extendedTextInteraction: { parents: ['stringInteraction', 'blockInteraction'], qti: true },\n inlineChoiceInteraction: { parents: ['inlineInteraction'], qti: true },\n endAttemptInteraction: { parents: ['inlineInteraction'], qti: true },\n customInteraction: { parents: ['block', 'flow', 'interaction'], qti: true },\n _container: { parents: ['block'], qti: true } //a pseudo class introduced in TAO\n },\n\n cache: { containable: {}, children: {}, parents: {} },\n\n getAllowedContainersElements(qtiClass, $container) {\n const classes = QtiElements.getAllowedContainers(qtiClass);\n let jqSelector = '';\n for (let i in classes) {\n if (!classes[i].qti) {\n //html element:\n jqSelector += `${classes[i]}, `;\n }\n }\n\n if (jqSelector) {\n jqSelector = jqSelector.substring(0, jqSelector.length - 2);\n }\n\n return $(jqSelector, $container ? $container : $(document)).filter(':not([data-qti-type])');\n },\n\n getAllowedContainers(qtiClass) {\n let ret;\n if (QtiElements.cache.containable[qtiClass]) {\n ret = QtiElements.cache.containable[qtiClass];\n } else {\n ret = [];\n const parents = QtiElements.getParentClasses(qtiClass, true);\n for (let aClass in QtiElements.classes) {\n const model = QtiElements.classes[aClass];\n if (model.contains) {\n const intersect = _.intersection(model.contains, parents);\n if (intersect.length) {\n if (!model.abstract) {\n ret.push(aClass);\n }\n ret = _.union(ret, QtiElements.getChildClasses(aClass, true));\n }\n }\n }\n QtiElements.cache.containable[qtiClass] = ret;\n }\n\n return ret;\n },\n\n getAllowedContents(qtiClass, recursive, checked) {\n let ret = [];\n checked = checked || {};\n\n const model = QtiElements.classes[qtiClass];\n if (model && model.contains) {\n for (let i in model.contains) {\n const contain = model.contains[i];\n if (!checked[contain]) {\n checked[contain] = true;\n\n //qtiClass can contain everything defined as its contents\n ret.push(contain);\n\n //qtiClass can also contain subclass of its contents\n const children = QtiElements.getChildClasses(contain, true);\n for (let j in children) {\n const child = children[j];\n if (!checked[child]) {\n checked[child] = true;\n\n ret.push(child);\n\n //adding children allowed contents depends on the option \"recursive\"\n if (recursive) {\n ret = _.union(ret, QtiElements.getAllowedContents(child, true, checked));\n }\n }\n }\n\n //adding allowed contents of qtiClass' allowed contents depends on the option \"recursive\"\n if (recursive) {\n ret = _.union(ret, QtiElements.getAllowedContents(contain, true, checked));\n }\n }\n }\n }\n\n //qtiClass can contain all allowed contents of its parents:\n const parents = QtiElements.getParentClasses(qtiClass, true);\n for (let i in parents) {\n ret = _.union(ret, QtiElements.getAllowedContents(parents[i], recursive, checked));\n }\n\n return _.uniq(ret, false);\n },\n\n isAllowedClass(qtiContainerClass, qtiContentClass) {\n const allowedClasses = QtiElements.getAllowedContents(qtiContainerClass);\n return _.indexOf(allowedClasses, qtiContentClass) >= 0;\n },\n\n getParentClasses(qtiClass, recursive) {\n let ret;\n if (recursive && QtiElements.cache.parents[qtiClass]) {\n ret = QtiElements.cache.parents[qtiClass];\n } else {\n ret = [];\n if (QtiElements.classes[qtiClass]) {\n ret = QtiElements.classes[qtiClass].parents;\n if (recursive) {\n for (let i in ret) {\n ret = _.union(ret, QtiElements.getParentClasses(ret[i], recursive));\n }\n ret = _.uniq(ret, false);\n }\n }\n QtiElements.cache.parents[qtiClass] = ret;\n }\n\n return ret;\n },\n\n getChildClasses(qtiClass, recursive, type) {\n let ret;\n const cacheType = type ? type : 'all';\n if (recursive && QtiElements.cache.children[qtiClass] && QtiElements.cache.children[qtiClass][cacheType]) {\n ret = QtiElements.cache.children[qtiClass][cacheType];\n } else {\n ret = [];\n for (let aClass in QtiElements.classes) {\n const model = QtiElements.classes[aClass];\n if (_.indexOf(model.parents, qtiClass) >= 0) {\n if (type) {\n if (model[type]) {\n ret.push(aClass);\n }\n } else {\n ret.push(aClass);\n }\n if (recursive) {\n ret = _.union(ret, QtiElements.getChildClasses(aClass, recursive, type));\n }\n }\n }\n if (!QtiElements.cache.children[qtiClass]) {\n QtiElements.cache.children[qtiClass] = {};\n }\n QtiElements.cache.children[qtiClass][cacheType] = ret;\n }\n\n return ret;\n },\n\n isBlock(qtiClass) {\n return QtiElements.is(qtiClass, 'block');\n },\n\n isInline(qtiClass) {\n return QtiElements.is(qtiClass, 'inline');\n },\n\n is(qtiClass, topClass) {\n if (qtiClass === topClass) {\n return true;\n } else {\n const parents = QtiElements.getParentClasses(qtiClass, true);\n return _.indexOf(parents, topClass) >= 0;\n }\n },\n\n /**\n * Check wether an element is visible, using the feature viibility service\n * @param {string} qtiClass - see the list of available classes\n * @returns {boolean} true by default and false only if the element is explicitely registered as hidden\n */\n isVisible(qtiClass) {\n if (this.is(qtiClass, 'customInteraction')) {\n return featuresService.isVisible(`taoQtiItem/creator/customInteraction/${qtiClass.replace(/Interaction$/, '').replace(/^customInteraction\\./, '')}`);\n }\n if (this.is(qtiClass, 'interaction')) {\n return featuresService.isVisible(`taoQtiItem/creator/interaction/${qtiClass.replace(/Interaction$/, '')}`);\n }\n return true;\n },\n\n /**\n * Get the list of available elements for the authoring side\n * The list of those element is statically defined, but we filter out elements that should be visible\n * @returns {Object} the available elements\n */\n getAvailableAuthoringElements() {\n const tagTitles = {\n commonInteractions: __('Common Interactions'),\n inlineInteractions: __('Inline Interactions'),\n graphicInteractions: __('Graphic Interactions')\n };\n\n const authoringElements = {\n choiceInteraction: {\n label: __('Choice Interaction'),\n description: __(\n 'Select a single (radio buttons) or multiple (check boxes) responses among a set of choices.'\n ),\n icon: 'icon-choice',\n short: __('Choice'),\n qtiClass: 'choiceInteraction',\n tags: [tagTitles.commonInteractions, 'mcq'],\n group: 'common-interactions'\n },\n orderInteraction: {\n label: __('Order Interaction'),\n icon: 'icon-order',\n description: __('Arrange a list of choices in the correct order.'),\n short: __('Order'),\n qtiClass: 'orderInteraction',\n tags: [tagTitles.commonInteractions, 'ordering'],\n group: 'common-interactions'\n },\n associateInteraction: {\n label: __('Associate Interaction'),\n icon: 'icon-associate',\n description: __('Create pair(s) from a series of choices.'),\n short: __('Associate'),\n qtiClass: 'associateInteraction',\n tags: [tagTitles.commonInteractions, 'association'],\n group: 'common-interactions'\n },\n matchInteraction: {\n label: __('Match Interaction'),\n icon: 'icon-match',\n description: __(\n 'Create association(s) between two sets of choices displayed in a table (row and column).'\n ),\n short: __('Match'),\n qtiClass: 'matchInteraction',\n tags: [tagTitles.commonInteractions, 'association'],\n group: 'common-interactions'\n },\n hottextInteraction: {\n label: __('Hottext Interaction'),\n icon: 'icon-hottext',\n description: __('Select one or more text parts (hottext) within a text.'),\n short: __('Hottext'),\n qtiClass: 'hottextInteraction',\n tags: [tagTitles.commonInteractions, 'text'],\n group: 'common-interactions'\n },\n gapMatchInteraction: {\n label: __('Gap Match Interaction'),\n icon: 'icon-gap-match',\n description: __(' Fill in the gaps in a text from a set of choices.'),\n short: __('Gap Match'),\n qtiClass: 'gapMatchInteraction',\n tags: [tagTitles.commonInteractions, 'text', 'association'],\n group: 'common-interactions'\n },\n sliderInteraction: {\n label: __('Slider Interaction'),\n icon: 'icon-slider',\n description: __('Select a value within a numerical range.'),\n short: __('Slider'),\n qtiClass: 'sliderInteraction',\n tags: [tagTitles.commonInteractions, 'special'],\n group: 'common-interactions'\n },\n extendedTextInteraction: {\n label: __('Extended Text Interaction'),\n icon: 'icon-extended-text',\n description: __(\n 'Collect open-ended information in one or more text area(s) (strings or numeric values).'\n ),\n short: __('Extended Text'),\n qtiClass: 'extendedTextInteraction',\n tags: [tagTitles.commonInteractions, 'text'],\n group: 'common-interactions'\n },\n uploadInteraction: {\n label: __('File Upload Interaction'),\n icon: 'icon-upload',\n description: __('Upload a file (e.g. document, picture...) as a response.'),\n short: __('File Upload'),\n qtiClass: 'uploadInteraction',\n tags: [tagTitles.commonInteractions, 'special'],\n group: 'common-interactions'\n },\n mediaInteraction: {\n label: __('Media Interaction'),\n icon: 'icon-media',\n description: __(\n 'Control the playing parameters (auto-start, loop) of a video or audio file and report the number of time it has been played.'\n ),\n short: __('Media'),\n qtiClass: 'mediaInteraction',\n tags: [tagTitles.commonInteractions, 'media'],\n group: 'common-interactions'\n },\n _container: {\n label: __('Text Block'),\n icon: 'icon-font',\n description: __(\n 'Block contains the content (stimulus) of the item such as text or image. It is also required for Inline Interactions.'\n ),\n short: __('Block'),\n qtiClass: '_container',\n tags: [tagTitles.inlineInteractions, 'text'],\n group: 'inline-interactions'\n },\n inlineChoiceInteraction: {\n label: __('Inline Choice Interaction'),\n icon: 'icon-inline-choice',\n description: __('Select a choice from a drop-down list.'),\n short: __('Inline Choice'),\n qtiClass: 'inlineChoiceInteraction',\n tags: [tagTitles.inlineInteractions, 'inline-interactions', 'mcq'],\n group: 'inline-interactions'\n },\n textEntryInteraction: {\n label: __('Text Entry Interaction'),\n icon: 'icon-text-entry',\n description: __(\n 'Collect open-ended information in a short text input (strings or numeric values).'\n ),\n short: __('Text Entry'),\n qtiClass: 'textEntryInteraction',\n tags: [tagTitles.inlineInteractions, 'inline-interactions', 'text'],\n group: 'inline-interactions'\n },\n endAttemptInteraction: {\n label: __('End Attempt Interaction'),\n icon: 'icon-end-attempt',\n description: __('Trigger the end of the item attempt.'),\n short: __('End Attempt'),\n qtiClass: 'endAttemptInteraction',\n tags: [tagTitles.inlineInteractions, 'inline-interactions', 'button', 'submit'],\n group: 'inline-interactions'\n },\n hotspotInteraction: {\n label: __('Hotspot Interaction'),\n icon: 'icon-hotspot',\n description: __('Select one or more areas (hotspots) displayed on an picture.'),\n short: __('Hotspot'),\n qtiClass: 'hotspotInteraction',\n tags: [tagTitles.graphicInteractions, 'mcq'],\n group: 'graphic-interactions'\n },\n graphicOrderInteraction: {\n label: __('Graphic Order Interaction'),\n icon: 'icon-graphic-order',\n description: __('Order the areas (hotspots) displayed on a picture.'),\n short: __('Order'),\n qtiClass: 'graphicOrderInteraction',\n tags: [tagTitles.graphicInteractions, 'ordering'],\n group: 'graphic-interactions'\n },\n graphicAssociateInteraction: {\n label: __('Graphic Associate Interaction'),\n icon: 'icon-graphic-associate',\n description: __('Create association(s) between areas (hotspots) displayed on a picture.'),\n short: __('Associate'),\n qtiClass: 'graphicAssociateInteraction',\n tags: [tagTitles.graphicInteractions, 'association'],\n group: 'graphic-interactions'\n },\n graphicGapMatchInteraction: {\n label: __('Graphic Gap Match Interaction'),\n icon: 'icon-graphic-gap',\n description: __('Fill in the gaps on a picture with a set of image choices.'),\n short: __('Gap Match'),\n qtiClass: 'graphicGapMatchInteraction',\n tags: [tagTitles.graphicInteractions, 'association'],\n group: 'graphic-interactions'\n },\n selectPointInteraction: {\n label: __('Select Point Interaction'),\n icon: 'icon-select-point',\n description: __('Position one or more points on a picture (response areas are not displayed).'),\n short: __('Select Point'),\n qtiClass: 'selectPointInteraction',\n tags: [tagTitles.graphicInteractions],\n group: 'graphic-interactions'\n }\n };\n\n //filter out hidden elements\n const availableElements = {};\n for (const [elementId, element] of Object.entries(authoringElements)) {\n if (this.isVisible(elementId)) {\n availableElements[elementId] = element;\n }\n }\n return availableElements;\n }\n };\n\n return QtiElements;\n});\n\n","/*\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2016-2022 (original work) Open Assessment Technologies SA;\n *\n */\ndefine('taoQtiItem/portableElementRegistry/factory/ciRegistry',[\n 'lodash',\n 'i18n',\n 'taoQtiItem/portableElementRegistry/factory/factory',\n 'taoQtiItem/qtiCreator/helper/qtiElements'\n], function (_, __, portableElementRegistry, qtiElements) {\n 'use strict';\n\n /**\n * Create a ney interaction registry instance\n * interaction registry need to register newly loaded creator hooks in the list of available qti authoring elements\n *\n * @returns {Object} registry instance\n */\n return function customInteractionRegistry() {\n return portableElementRegistry({\n /**\n * Get the authoring information for a given custom interaction\n * @param {string} typeIdentifier - the interaction type identifier\n * @param {Object} [options]\n * @param {string|number} [options.version] - the interaction version\n * @param {boolean} [options.enabledOnly] - to only get interaction enabled && visible\n * @returns {Object} the authoring info\n */\n getAuthoringData(typeIdentifier, options = {}) {\n options = _.defaults(options || {}, { version: 0, enabledOnly: false });\n const pciModel = this.get(typeIdentifier, options.version);\n const qtiClass = `customInteraction.${pciModel.typeIdentifier}`;\n if (\n pciModel &&\n pciModel.creator &&\n pciModel.creator.hook &&\n pciModel.creator.icon &&\n ((pciModel.enabled && qtiElements.isVisible(qtiClass)) || !options.enabledOnly)\n ) {\n return {\n label: pciModel.label, //currently no translation available\n icon: pciModel.creator.icon.replace(new RegExp(`^${typeIdentifier}/`), pciModel.baseUrl),\n short: pciModel.short,\n description: pciModel.description,\n qtiClass, //custom interaction is block type\n tags: _.union([__('Custom Interactions')], pciModel.tags),\n group: 'custom-interactions'\n };\n }\n }\n }).on('creatorsloaded', function () {\n const creators = this.getLatestCreators();\n _.forEach(creators, function (creator, typeIdentifier) {\n qtiElements.classes[`customInteraction.${typeIdentifier}`] = {\n parents: ['customInteraction'],\n qti: true\n };\n });\n });\n };\n});\n\n","/*\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2016 (original work) Open Assessment Technologies SA;\n *\n */\ndefine('taoQtiItem/portableElementRegistry/ciRegistry',['lodash', 'taoQtiItem/portableElementRegistry/factory/ciRegistry', 'module'], function (_, ciRegistry, module){\n 'use strict';\n\n //create a preregistered singleton of ciRegistry\n var registry = ciRegistry();\n var providers = [];\n var config = module.config();\n\n if(config && config.providers){\n providers = config.providers;\n }\n\n _.each(providers, function(provider){\n if(provider.name && provider.module){\n registry.registerProvider(provider.module);\n }\n });\n\n return registry;\n});\n","/*\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2016 (original work) Open Assessment Technologies SA;\n *\n */\ndefine('taoQtiItem/portableElementRegistry/factory/icRegistry',[\n 'lodash',\n 'taoQtiItem/portableElementRegistry/factory/factory'\n], function (_, portableElementRegistry){\n 'use strict';\n\n /**\n * Info control registry has currently no additonal fonctionalities than the basic portable element registry\n *\n * @returns {Object} registry instance\n */\n return function infoControlRegistry(){\n return portableElementRegistry();\n }\n\n});\n","/*\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2016 (original work) Open Assessment Technologies SA;\n *\n */\ndefine('taoQtiItem/portableElementRegistry/icRegistry',['lodash', 'taoQtiItem/portableElementRegistry/factory/icRegistry', 'module'], function (_, icRegistry, module){\n 'use strict';\n\n //create a preregistered singleton of icRegistry\n var registry = icRegistry();\n var providers = [];\n var config = module.config();\n\n if(config && config.providers){\n providers = config.providers;\n }\n\n _.each(providers, function(provider){\n if(provider.name && provider.module){\n registry.registerProvider(provider.module);\n }\n });\n\n return registry;\n});\n","/**\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2016 (original work) Open Assessment Technologies SA;\n */\n\ndefine('taoQtiItem/portableElementRegistry/assetManager/portableAssetStrategy',[\n 'taoQtiItem/portableElementRegistry/ciRegistry',\n 'taoQtiItem/portableElementRegistry/icRegistry'\n], function (ciRegistry, icRegistry) {\n 'use strict';\n\n function getBaseUrlByIdentifier(typeIdentifier) {\n if (ciRegistry.get(typeIdentifier)) {\n return ciRegistry.getBaseUrl(typeIdentifier);\n }\n if (icRegistry.get(typeIdentifier)) {\n return icRegistry.getBaseUrl(typeIdentifier);\n }\n return typeIdentifier;\n }\n\n //strategy to resolve portable info control and portable interactions paths.\n //It should never be reached in the stack the usual way and should be called only using resolveBy.\n return {\n name: 'portableElementLocation',\n handle: function handlePortableElementLocation(url) {\n\n if (url.file === url.path) {\n return getBaseUrlByIdentifier(url.file);\n } else if (url.source === url.relative) {\n return url.relative.replace(/^(\\.\\/)?([a-z_0-9]+)\\/(.*)/i, function (fullmatch, $1, typeIdentifier, relPath) {\n var runtimeLocation = getBaseUrlByIdentifier(typeIdentifier);\n if (runtimeLocation) {\n return runtimeLocation + '/' + relPath;\n }\n return fullmatch;\n });\n }\n }\n };\n});\n","define('taoQtiItem/qtiCommonRenderer/renderers/config',['lodash', 'context', 'ui/themes', 'taoItems/assets/manager', 'taoItems/assets/strategies', 'module', 'taoQtiItem/portableElementRegistry/assetManager/portableAssetStrategy'], function (_, context, themes, assetManagerFactory, assetStrategies, module, portableAssetStrategy) { 'use strict';\n\n _ = _ && Object.prototype.hasOwnProperty.call(_, 'default') ? _['default'] : _;\n context = context && Object.prototype.hasOwnProperty.call(context, 'default') ? context['default'] : context;\n themes = themes && Object.prototype.hasOwnProperty.call(themes, 'default') ? themes['default'] : themes;\n assetManagerFactory = assetManagerFactory && Object.prototype.hasOwnProperty.call(assetManagerFactory, 'default') ? assetManagerFactory['default'] : assetManagerFactory;\n assetStrategies = assetStrategies && Object.prototype.hasOwnProperty.call(assetStrategies, 'default') ? assetStrategies['default'] : assetStrategies;\n module = module && Object.prototype.hasOwnProperty.call(module, 'default') ? module['default'] : module;\n portableAssetStrategy = portableAssetStrategy && Object.prototype.hasOwnProperty.call(portableAssetStrategy, 'default') ? portableAssetStrategy['default'] : portableAssetStrategy;\n\n /**\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2014 (original work) Open Assessment Technologies SA;\n */\n\n var itemThemes = themes.get('items');\n var moduleConfig = module.config();\n\n //Create asset manager stack\n var assetManager = assetManagerFactory(\n [\n {\n name: 'theme',\n handle: function handleTheme(url) {\n if (\n itemThemes &&\n url.path &&\n (url.path === itemThemes.base || _.contains(_.pluck(itemThemes.available, 'path'), url.path))\n ) {\n return context.root_url + url.toString();\n }\n }\n },\n assetStrategies.taomedia,\n assetStrategies.external,\n assetStrategies.base64,\n assetStrategies.itemCssNoCache,\n assetStrategies.baseUrl,\n portableAssetStrategy\n ],\n { baseUrl: '' }\n ); //baseUrl is not predefined in the config, but should be set upon renderer instantiating\n\n //renderers locations\n var locations = {\n assessmentItem: 'taoQtiItem/qtiCommonRenderer/renderers/Item',\n _container: 'taoQtiItem/qtiCommonRenderer/renderers/Container',\n _simpleFeedbackRule: false,\n _tooltip: 'taoQtiItem/qtiCommonRenderer/renderers/Tooltip',\n stylesheet: 'taoQtiItem/qtiCommonRenderer/renderers/Stylesheet',\n outcomeDeclaration: false,\n responseDeclaration: false,\n responseProcessing: false,\n figure: 'taoQtiItem/qtiCommonRenderer/renderers/Figure',\n img: 'taoQtiItem/qtiCommonRenderer/renderers/Img',\n figcaption: 'taoQtiItem/qtiCommonRenderer/renderers/Figcaption',\n math: 'taoQtiItem/qtiCommonRenderer/renderers/Math',\n object: 'taoQtiItem/qtiCommonRenderer/renderers/Object',\n table: 'taoQtiItem/qtiCommonRenderer/renderers/Table',\n printedVariable: 'taoQtiItem/qtiCommonRenderer/renderers/PrintedVariable',\n rubricBlock: 'taoQtiItem/qtiCommonRenderer/renderers/RubricBlock',\n modalFeedback: 'taoQtiItem/qtiCommonRenderer/renderers/ModalFeedback',\n prompt: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/Prompt',\n choiceInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/ChoiceInteraction',\n extendedTextInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/ExtendedTextInteraction',\n orderInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/OrderInteraction',\n associateInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/AssociateInteraction',\n matchInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/MatchInteraction',\n textEntryInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/TextEntryInteraction',\n sliderInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/SliderInteraction',\n inlineChoiceInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/InlineChoiceInteraction',\n 'simpleChoice.choiceInteraction': 'taoQtiItem/qtiCommonRenderer/renderers/choices/SimpleChoice.ChoiceInteraction',\n 'simpleChoice.orderInteraction': 'taoQtiItem/qtiCommonRenderer/renderers/choices/SimpleChoice.OrderInteraction',\n hottext: 'taoQtiItem/qtiCommonRenderer/renderers/choices/Hottext',\n gap: 'taoQtiItem/qtiCommonRenderer/renderers/choices/Gap',\n gapText: 'taoQtiItem/qtiCommonRenderer/renderers/choices/GapText',\n 'simpleAssociableChoice.matchInteraction':\n 'taoQtiItem/qtiCommonRenderer/renderers/choices/SimpleAssociableChoice.MatchInteraction',\n 'simpleAssociableChoice.associateInteraction':\n 'taoQtiItem/qtiCommonRenderer/renderers/choices/SimpleAssociableChoice.AssociateInteraction',\n inlineChoice: 'taoQtiItem/qtiCommonRenderer/renderers/choices/InlineChoice',\n hottextInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/HottextInteraction',\n hotspotInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/HotspotInteraction',\n hotspotChoice: false,\n gapMatchInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/GapMatchInteraction',\n selectPointInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/SelectPointInteraction',\n graphicOrderInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/GraphicOrderInteraction',\n mediaInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/MediaInteraction',\n uploadInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/UploadInteraction',\n graphicGapMatchInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/GraphicGapMatchInteraction',\n gapImg: 'taoQtiItem/qtiCommonRenderer/renderers/choices/GapImg',\n graphicAssociateInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/GraphicAssociateInteraction',\n associableHotspot: false,\n customInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/PortableCustomInteraction',\n infoControl: 'taoQtiItem/qtiCommonRenderer/renderers/PortableInfoControl',\n include: 'taoQtiItem/qtiCommonRenderer/renderers/Include',\n endAttemptInteraction: 'taoQtiItem/qtiCommonRenderer/renderers/interactions/EndAttemptInteraction'\n };\n\n var config = {\n name: 'commonRenderer',\n locations: locations,\n options: {\n assetManager: assetManager,\n themes: itemThemes,\n enableDragAndDrop: {\n associate: !!moduleConfig.associateDragAndDrop,\n gapMatch: !!moduleConfig.gapMatchDragAndDrop,\n graphicGapMatch: !!moduleConfig.graphicGapMatchDragAndDrop,\n order: !!moduleConfig.orderDragAndDrop\n },\n messages: moduleConfig.messages\n }\n };\n\n return config;\n\n});\n\n","define('taoQtiItem/qtiCommonRenderer/renderers/Renderer',['taoQtiItem/qtiRunner/core/Renderer', 'taoQtiItem/qtiCommonRenderer/renderers/config'], function (Renderer$1, config) { 'use strict';\n\n\tRenderer$1 = Renderer$1 && Object.prototype.hasOwnProperty.call(Renderer$1, 'default') ? Renderer$1['default'] : Renderer$1;\n\tconfig = config && Object.prototype.hasOwnProperty.call(config, 'default') ? config['default'] : config;\n\n\t/**\n\t * This program is free software; you can redistribute it and/or\n\t * modify it under the terms of the GNU General Public License\n\t * as published by the Free Software Foundation; under version 2\n\t * of the License (non-upgradable).\n\t *\n\t * This program is distributed in the hope that it will be useful,\n\t * but WITHOUT ANY WARRANTY; without even the implied warranty of\n\t * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n\t * GNU General Public License for more details.\n\t *\n\t * You should have received a copy of the GNU General Public License\n\t * along with this program; if not, write to the Free Software\n\t * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n\t *\n\t * Copyright (c) 2014 (original work) Open Assessment Technologies SA;\n\t */\n\n\tvar Renderer = Renderer$1.build(config.locations, config.name, config.options);\n\n\treturn Renderer;\n\n});\n\n","define('taoQtiItem/runner/provider/manager/userModules',['lodash', 'module'], function (_, module) { 'use strict';\n\n _ = _ && Object.prototype.hasOwnProperty.call(_, 'default') ? _['default'] : _;\n module = module && Object.prototype.hasOwnProperty.call(module, 'default') ? module['default'] : module;\n\n /**\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2016 (original work) Open Assessment Technologies SA ;\n */\n\n var userModules = {\n /**\n * Load user modules defined in the module config\n * @param {Array} [userModules] - manually specify user modules to load instead of getting them from the module config\n * @returns {Promise}\n */\n load: function load(userModules) {\n var config = module.config();\n\n if (!userModules || !_.isArray(userModules)) {\n if (config && config.userModules && _.isArray(config.userModules)) {\n userModules = config.userModules;\n } else {\n userModules = [];\n }\n }\n if(!userModules.length){\n return Promise.resolve();\n }\n return new Promise(function(resolve, reject) {\n window.require(userModules, function() {\n _.forEach(arguments, function(dependency) {\n if (dependency && _.isFunction(dependency.exec)) {\n dependency.exec();\n }\n });\n resolve();\n }, function(err) {\n reject(err.message);\n });\n });\n }\n };\n\n return userModules;\n\n});\n\n","/**\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2014 (original work) Open Assessment Technologies SA (under the project TAO-PRODUCT);\n */\ndefine('taoQtiItem/runtime/qtiBootstrap',[\n 'jquery',\n 'lodash',\n 'module',\n 'taoQtiItem/qtiRunner/core/QtiRunner',\n 'taoQtiItem/qtiCommonRenderer/renderers/Renderer',\n 'iframeNotifier',\n 'core/history',\n 'taoQtiItem/runner/provider/manager/userModules'\n], function($, _, module, QtiRunner, Renderer, iframeNotifier, history, userModules){\n 'use strict';\n\n //fix backspace going back into the history\n history.fixBrokenBrowsers();\n\n /**\n * The bootstrap is used to set up a QTI item at runtime. It connects to the itemApi.\n *\n * @author Bertrand Chevrier \n * @exports taoQtiItem/runtime/qtiBootstrap\n *\n * @param {Object} runnerContext - the item context\n */\n return function bootstrap (runnerContext){\n\n //reconnect to global itemApi function\n window.onItemApiReady = function onItemApiReady(itemApi) {\n var qtiRunner = new QtiRunner();\n var coreItemData = runnerContext.itemData;\n var variableElementsData = _.merge(runnerContext.variableElements, itemApi.params.contentVariables || {});\n\n var renderer = new Renderer();\n\n // Makes the runner interface available from outside the frame\n // for preview.\n window.qtiRunner = qtiRunner;\n\n qtiRunner.setItemApi(itemApi);\n qtiRunner.setRenderer(renderer);\n\n qtiRunner.loadItemData(coreItemData, function() {\n\n qtiRunner.loadElements(variableElementsData, function() {\n\n qtiRunner.renderItem(undefined, function() {\n\n //userModules loading\n //we use any user modules bound to this module configuration instead of the ones bound to the new test runner\n var userModulesOverride;\n var config = module.config();\n if (config && config.userModules && _.isArray(config.userModules) && config.userModules.length > 0) {\n userModulesOverride = config.userModules;\n }\n userModules.load(userModulesOverride)\n .then(function() {\n\n //exec user scripts\n if (_.isArray(runnerContext.userScripts)) {\n require(runnerContext.userScripts, function() {\n _.forEach(arguments, function(dependency) {\n if (_.isFunction(dependency.exec)) {\n dependency.exec.call(null, runnerContext.userVars);\n }\n });\n });\n }\n\n iframeNotifier.parent('itemloaded');\n\n //IE9/10 loose the iframe focus, so we force getting it back.\n _.defer(function(){\n window.focus();\n });\n })\n .catch(function(err) {\n throw new Error('Error in user modules : ' + err.message);\n });\n\n });\n });\n });\n };\n\n //if the item is longer to load,\n _.defer(function(){\n //tell the parent to connect the item api\n iframeNotifier.parent('itemready');\n });\n\n };\n});\n\n\n","/**\n * This program is free software; you can redistribute it and/or\n * modify it under the terms of the GNU General Public License\n * as published by the Free Software Foundation; under version 2\n * of the License (non-upgradable).\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program; if not, write to the Free Software\n * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.\n *\n * Copyright (c) 2014 (original work) Open Assessment Technologies SA (under the project TAO-PRODUCT);\n */\n\ndefine('taoQtiItem/runtime/qtiLoader',[\n 'taoQtiItem/runtime/qtiBootstrap',\n 'css!taoCss/tao-main-style'\n], function(qtiBootstrap){\n 'use strict';\n\n return {\n start : function start(){\n //the context is set into the template and bound to the tao namespace in global scope\n var runnerContext = window.tao.qtiRunnerContext;\n qtiBootstrap(runnerContext);\n }\n };\n});\n\n","\ndefine(\"taoQtiItem/loader/qtiLoader.bundle\", function(){});\n","window.bundles = (window.bundles || []).concat([\"taoQtiItem/loader/taoQtiItem.min\"]);\n"],"mappings":"ACsBA,YACA,gBAIA,CAAAA,YAAA,CAAAC,QAAA,CAAAC,cAAA,eACAC,SAAA,CAAAH,YAAA,CAAAI,YAAA,gBACAC,MAAA,CAAAL,YAAA,CAAAI,YAAA,gBAEAE,cAAA,UAAAA,eAAA,KACA,CAAAC,iBAAA,IACAC,cAAA,CAAAR,YAAA,CAAAI,YAAA,oBACAK,MAAA,CAAAT,YAAA,CAAAI,YAA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phB,GAAA,EACA,UAAAkH,KAAA,4BAAAlH,GAAA,CAAA+d,OAAA,CACA,EAEA,EACA,EACA,EACA,EAGAxZ,CAAA,CAAA43B,KAAA,YAEAzf,cAAA,CAAA3V,MAAA,aACA,EAEA,CACA,GCzFA5F,MAAA,iCACA,kCACA,4BACA,UAAAk7B,YAAA,EACA,aAEA,OACA/7B,KAAA,UAAAA,MAAA,EAEA,IAAAk7B,aAAA,CAAAv7B,MAAA,CAAAq8B,GAAA,CAAAC,gBAAA,CACAF,YAAA,CAAAb,aAAA,CACA,CACA,CACA,GC9BAr6B,MAAA,oDACAlB,MCFA,CAAAU,OAAA,EAAAV,MAAA,CAAAU,OAAA,MAAAC,MAAA"} \ No newline at end of file diff --git a/views/js/loader/taoQtiItem.min.js b/views/js/loader/taoQtiItem.min.js index 20465ec9a3..2e6be8b51b 100644 --- a/views/js/loader/taoQtiItem.min.js +++ b/views/js/loader/taoQtiItem.min.js @@ -1,2 +1,2 @@ -define("taoQtiItem/portableElementRegistry/factory/factory",["lodash","core/promise","core/eventifier"],function(_,Promise,eventifier){"use strict";var _requirejs=window.require,_defaultLoadingOptions={reload:!1},loadModuleConfig=function loadModuleConfig(manifest){return new Promise(function(resolve,reject){var requireConfigAliases={},reqConfigs=[],modules={},baseUrl;return manifest&&manifest.runtime?void(baseUrl=manifest.baseUrl,_.isArray(manifest.runtime.config)&&manifest.runtime.config.length&&_.forEach(manifest.runtime.config,function(pciConfig){_.isString(pciConfig)?reqConfigs.push("json!"+baseUrl+"/"+pciConfig):pciConfig.data?modules=_.defaults(modules,pciConfig.data.paths||{}):pciConfig.file&&reqConfigs.push("json!"+baseUrl+"/"+pciConfig.file)}),require(reqConfigs,function(){var runtimeModules={};requireConfigAliases[manifest.typeIdentifier]=baseUrl,"IMSPCI"===manifest.model&&(modules=_.reduce(arguments,function(acc,conf){return _.defaults(acc,conf.paths||{})},modules),_.forEach(manifest.runtime.modules||{},function(paths,id){paths&&(_.isString(paths)||_.isArray(paths)&&paths.length)&&(runtimeModules[id]=paths)}),modules=_.merge(modules,runtimeModules),_.forEach(modules,function(paths,id){paths=_.isArray(paths)?paths:[paths],requireConfigAliases[id]=_.map(paths,function(path){return baseUrl+"/"+path.replace(/\.js$/,"")})})),resolve(requireConfigAliases)},reject)):reject("invalid manifest")})},isPortableElementProvider=function isPortableElementProvider(provider){return provider&&_.isFunction(provider.load)};return function portableElementRegistry(methods){var _loaded=!1,__providers={};return eventifier(_.defaults(methods||{},{_registry:{},get:function get(typeIdentifier,version){if(this._registry[typeIdentifier])return version?_.find(this._registry[typeIdentifier],{version:version}):_.last(this._registry[typeIdentifier])},registerProvider:function registerProvider(moduleName,provider){return __providers[moduleName]=isPortableElementProvider(provider)?provider:null,_loaded=!1,this},resetProviders:function resetProviders(){return __providers={},_loaded=!1,this},loadProviders:function loadProviders(options){var self=this,loadPromise;return loadPromise=_loaded&&!options.reload?Promise.resolve([]):new Promise(function(resolve,reject){var providerLoadingStack=[];_.forIn(__providers,function(provider,id){null===provider&&providerLoadingStack.push(id)}),_requirejs(providerLoadingStack,function(){_.each([].slice.call(arguments),function(provider){isPortableElementProvider(provider)&&(__providers[providerLoadingStack.shift()]=provider)}),resolve(__providers),_loaded=!0,self.trigger("providersloaded",__providers)},reject)}),loadPromise},getAllVersions:function getAllVersions(){var all={};return _.forIn(this._registry,function(versions,id){all[id]=_.map(versions,"version")}),all},getRuntime:function getRuntime(typeIdentifier,version){var portableElement=this.get(typeIdentifier,version);return portableElement?_.assign(portableElement.runtime,{id:portableElement.typeIdentifier,label:portableElement.label,baseUrl:portableElement.baseUrl,model:portableElement.model}):void this.trigger("error",{message:"no portable element runtime found",typeIdentifier:typeIdentifier,version:version})},getCreator:function getCreator(typeIdentifier,version){var portableElement=this.get(typeIdentifier,version);return portableElement&&portableElement.creator?_.assign(portableElement.creator,{id:portableElement.typeIdentifier,label:portableElement.label,baseUrl:portableElement.baseUrl,response:portableElement.response,model:portableElement.model,xmlns:portableElement.xmlns}):void this.trigger("error",{message:"no portable element runtime found",typeIdentifier:typeIdentifier,version:version})},getLatestCreators:function getLatestCreators(){var all={};return _.forIn(this._registry,function(versions,id){var lastVersion=_.last(versions);lastVersion.creator&&lastVersion.creator.hook&&lastVersion.enabled&&(all[id]=lastVersion)}),all},getBaseUrl:function getBaseUrl(typeIdentifier,version){var runtime=this.get(typeIdentifier,version);return runtime?runtime.baseUrl:""},loadRuntimes:function loadRuntimes(options){var self=this,loadPromise;return options=_.defaults(options||{},_defaultLoadingOptions),loadPromise=self.loadProviders(options).then(function(providers){var loadStack=[];return _.forEach(providers,function(provider){provider&&loadStack.push(provider.load())}),Promise.all(loadStack).then(function(results){var configLoadingStack=[];return self._registry=_.reduce(results,function(acc,_pcis){return _.merge(acc,_pcis)},self._registry||{}),_.forIn(self._registry,function(versions,typeIdentifier){return!!(_.isArray(options.include)&&0>_.indexOf(options.include,typeIdentifier))||void configLoadingStack.push(loadModuleConfig(self.get(typeIdentifier)))}),Promise.all(configLoadingStack).then(function(moduleConfigs){var requireConfigAliases=_.reduce(moduleConfigs,function(acc,paths){return _.merge(acc,paths)},{});_requirejs.config({paths:requireConfigAliases})})})}),loadPromise.then(function(){self.trigger("runtimesloaded")}).catch(function(err){self.trigger("error",err)}),loadPromise},loadCreators:function loadCreators(options){var self=this,loadPromise;return options=_.defaults(options||{},_defaultLoadingOptions),loadPromise=self.loadRuntimes(options).then(function(){var requiredCreatorHooks=[];return _.forIn(self._registry,function(versions,typeIdentifier){var portableElementModel=self.get(typeIdentifier);if(portableElementModel.creator&&portableElementModel.creator.hook){if(portableElementModel.enabled){if(_.isArray(options.include)&&0>_.indexOf(options.include,typeIdentifier))return!0;}else if(!_.isArray(options.include)||0>_.indexOf(options.include,typeIdentifier))return!0;requiredCreatorHooks.push(portableElementModel.creator.hook.replace(/\.js$/,""))}}),requiredCreatorHooks.length?new Promise(function(resolve,reject){_requirejs(requiredCreatorHooks,function(){var creators={};_.each(arguments,function(creatorHook){var id=creatorHook.getTypeIdentifier(),portableElementModel=self.get(id),i=_.findIndex(self._registry[id],{version:portableElementModel.version});0>i?self.trigger("error","no creator found for id/version "+id+"/"+portableElementModel.version):(self._registry[id][i].creator.module=creatorHook,creators[id]=creatorHook)}),resolve(creators)},reject)}):Promise.resolve({})}),loadPromise.then(function(creators){return self.trigger("creatorsloaded",creators),creators}).catch(function(err){self.trigger("error",err)}),loadPromise},enable:function enable(typeIdentifier,version){var portableElement=this.get(typeIdentifier,version);return portableElement&&(portableElement.enabled=!0),this},disable:function disable(typeIdentifier,version){var portableElement=this.get(typeIdentifier,version);return portableElement&&(portableElement.enabled=!1),this},isEnabled:function isEnabled(typeIdentifier,version){var portableElement=this.get(typeIdentifier,version);return portableElement&&!0===portableElement.enabled}}))}}),define("taoQtiItem/qtiCreator/helper/qtiElements",["jquery","lodash","i18n","services/features"],function($,_,__,featuresService){"use strict";const QtiElements={classes:{itemBody:{parents:["bodyElement"],contains:["block"],abstract:!0},atomicBlock:{parents:["blockStatic","bodyElement","flowStatic"],contains:["inline"],abstract:!0},atomicInline:{parents:["bodyElement","flowStatic","inlineStatic"],contains:["inline"],abstract:!0},simpleBlock:{parents:["blockStatic","bodyElement","flowStatic"],contains:["block"],abstract:!0},simpleInline:{parents:["bodyElement","flowStatic","inlineStatic"],contains:["inline"],abstract:!0},flowStatic:{parents:["flow"],abstract:!0},blockStatic:{parents:["block"],abstract:!0},inlineStatic:{parents:["inline"],abstract:!0},flow:{parents:["objectFlow"],abstract:!0},tableCell:{parents:["bodyElement"],contains:["flow"],abstract:!0},caption:{parents:["bodyElement"],contains:["inline"],xhtml:!0},col:{parents:["bodyElement"],xhtml:!0},colgroup:{parents:["bodyElement"],contains:["col"],xhtml:!0},div:{parents:["blockStatic","bodyElement","flowStatic"],contains:["flow"],xhtml:!0},dl:{parents:["blockStatic","bodyElement","flowStatic"],contains:["dlElement"],xhtml:!0},dt:{parents:["dlElement"],contains:["inline"],xhtml:!0},dd:{parents:["dlElement"],contains:["flow"],xhtml:!0},hr:{parents:["blockStatic","bodyElement","flowStatic"],xhtml:!0},math:{parents:["blockStatic","flowStatic","inlineStatic"],xhtml:!0},li:{parents:["bodyElement"],contains:["flow"],xhtml:!0},ol:{parents:["blockStatic","bodyElement","flowStatic"],contains:["li"],xhtml:!0},ul:{parents:["blockStatic","bodyElement","flowStatic"],contains:["li"],xhtml:!0},object:{parents:["bodyElement","flowStatic","inlineStatic"],contains:["objectFlow"],xhtml:!0},param:{parents:["objectFlow"],xhtml:!0},table:{parents:["blockStatic","bodyElement","flowStatic"],contains:["caption","col","colgroup","thead","tfoot","tbody"],xhtml:!0},tbody:{parents:["bodyElement"],contains:["tr"],xhtml:!0},tfoot:{parents:["bodyElement"],contains:["tr"],xhtml:!0},thead:{parents:["bodyElement"],contains:["tr"],xhtml:!0},td:{parents:["tableCell"],xhtml:!0},th:{parents:["tableCell"],xhtml:!0},tr:{parents:["bodyElement"],contains:["tableCell"],xhtml:!0},a:{parents:["simpleInline"],xhtml:!0},abbr:{parents:["simpleInline"],xhtml:!0},acronym:{parents:["simpleInline"],xhtml:!0},b:{parents:["simpleInline"],xhtml:!0},big:{parents:["simpleInline"],xhtml:!0},cite:{parents:["simpleInline"],xhtml:!0},code:{parents:["simpleInline"],xhtml:!0},dfn:{parents:["simpleInline"],xhtml:!0},em:{parents:["simpleInline"],xhtml:!0},i:{parents:["simpleInline"],xhtml:!0},kbd:{parents:["simpleInline"],xhtml:!0},q:{parents:["simpleInline"],xhtml:!0},samp:{parents:["simpleInline"],xhtml:!0},small:{parents:["simpleInline"],xhtml:!0},span:{parents:["simpleInline"],xhtml:!0},strong:{parents:["simpleInline"],xhtml:!0},sub:{parents:["simpleInline"],xhtml:!0},sup:{parents:["simpleInline"],xhtml:!0},tt:{parents:["simpleInline"],xhtml:!0},var:{parents:["simpleInline"],xhtml:!0},blockquote:{parents:["simpleBlock"],xhtml:!0},address:{parents:["atomicBlock"],xhtml:!0},h1:{parents:["atomicBlock"],xhtml:!0},h2:{parents:["atomicBlock"],xhtml:!0},h3:{parents:["atomicBlock"],xhtml:!0},h4:{parents:["atomicBlock"],xhtml:!0},h5:{parents:["atomicBlock"],xhtml:!0},h6:{parents:["atomicBlock"],xhtml:!0},p:{parents:["atomicBlock"],xhtml:!0},pre:{parents:["atomicBlock"],xhtml:!0},img:{parents:["atomicInline"],xhtml:!0,attributes:["src","alt","longdesc","height","width"]},br:{parents:["atomicInline"],xhtml:!0},infoControl:{parents:["blockStatic","bodyElement","flowStatic"],qti:!0},textRun:{parents:["inlineStatic","flowstatic"],qti:!0},feedbackInline:{parents:["simpleInline","feedbackElement"],qti:!0},feedbackBlock:{parents:["simpleBlock"],qti:!0},rubricBlock:{parents:["simpleBlock"],qti:!0},blockInteraction:{parents:["block","flow","interaction"],qti:!0},inlineInteraction:{parents:["inline","flow","interaction"],qti:!0},gap:{parents:["inlineStatic"],qti:!0},hottext:{parents:["flowstatic","inlineStatic"],contains:["inlineStatic"],qti:!0},printedVariable:{parents:["bodyElement","flowStatic","inlineStatic","textOrVariable"],qti:!0},prompt:{parents:["bodyElement"],contains:["inlineStatic"],qti:!0},templateElement:{parents:["bodyElement"],qti:!0},templateBlock:{parents:["blockStatic","flowStatic","templateElement"],contains:["blockStatic"],qti:!0},templateInline:{parents:["inlineStatic","flowStatic","templateElement"],contains:["inlineStatic"],qti:!0},choiceInteraction:{parents:["blockInteraction"],qti:!0},associateInteraction:{parents:["blockInteraction"],qti:!0},orderInteraction:{parents:["blockInteraction"],qti:!0},matchInteraction:{parents:["blockInteraction"],qti:!0},hottextInteraction:{parents:["blockInteraction"],qti:!0},gapMatchInteraction:{parents:["blockInteraction"],qti:!0},mediaInteraction:{parents:["blockInteraction"],qti:!0},sliderInteraction:{parents:["blockInteraction"],qti:!0},uploadInteraction:{parents:["blockInteraction"],qti:!0},drawingInteraction:{parents:["blockInteraction"],qti:!0},graphicInteraction:{parents:["blockInteraction"],qti:!0},hotspotInteraction:{parents:["graphicInteraction"],qti:!0},graphicAssociateInteraction:{parents:["graphicInteraction"],qti:!0},graphicOrderInteraction:{parents:["graphicInteraction"],qti:!0},graphicGapMatchInteraction:{parents:["graphicInteraction"],qti:!0},selectPointInteraction:{parents:["graphicInteraction"],qti:!0},textEntryInteraction:{parents:["stringInteraction","inlineInteraction"],qti:!0},extendedTextInteraction:{parents:["stringInteraction","blockInteraction"],qti:!0},inlineChoiceInteraction:{parents:["inlineInteraction"],qti:!0},endAttemptInteraction:{parents:["inlineInteraction"],qti:!0},customInteraction:{parents:["block","flow","interaction"],qti:!0},_container:{parents:["block"],qti:!0}},cache:{containable:{},children:{},parents:{}},getAllowedContainersElements(qtiClass,$container){const classes=QtiElements.getAllowedContainers(qtiClass);let jqSelector="";for(let i in classes)classes[i].qti||(jqSelector+=`${classes[i]}, `);return jqSelector&&(jqSelector=jqSelector.substring(0,jqSelector.length-2)),$(jqSelector,$container?$container:$(document)).filter(":not([data-qti-type])")},getAllowedContainers(qtiClass){let ret;if(QtiElements.cache.containable[qtiClass])ret=QtiElements.cache.containable[qtiClass];else{ret=[];const parents=QtiElements.getParentClasses(qtiClass,!0);for(let aClass in QtiElements.classes){const model=QtiElements.classes[aClass];if(model.contains){const intersect=_.intersection(model.contains,parents);intersect.length&&(!model.abstract&&ret.push(aClass),ret=_.union(ret,QtiElements.getChildClasses(aClass,!0)))}}QtiElements.cache.containable[qtiClass]=ret}return ret},getAllowedContents(qtiClass,recursive,checked){let ret=[];checked=checked||{};const model=QtiElements.classes[qtiClass];if(model&&model.contains)for(let i in model.contains){const contain=model.contains[i];if(!checked[contain]){checked[contain]=!0,ret.push(contain);const children=QtiElements.getChildClasses(contain,!0);for(let j in children){const child=children[j];checked[child]||(checked[child]=!0,ret.push(child),recursive&&(ret=_.union(ret,QtiElements.getAllowedContents(child,!0,checked))))}recursive&&(ret=_.union(ret,QtiElements.getAllowedContents(contain,!0,checked)))}}const parents=QtiElements.getParentClasses(qtiClass,!0);for(let i in parents)ret=_.union(ret,QtiElements.getAllowedContents(parents[i],recursive,checked));return _.uniq(ret,!1)},isAllowedClass(qtiContainerClass,qtiContentClass){const allowedClasses=QtiElements.getAllowedContents(qtiContainerClass);return 0<=_.indexOf(allowedClasses,qtiContentClass)},getParentClasses(qtiClass,recursive){let ret;if(recursive&&QtiElements.cache.parents[qtiClass])ret=QtiElements.cache.parents[qtiClass];else{if(ret=[],QtiElements.classes[qtiClass]&&(ret=QtiElements.classes[qtiClass].parents,recursive)){for(let i in ret)ret=_.union(ret,QtiElements.getParentClasses(ret[i],recursive));ret=_.uniq(ret,!1)}QtiElements.cache.parents[qtiClass]=ret}return ret},getChildClasses(qtiClass,recursive,type){let ret;const cacheType=type?type:"all";if(recursive&&QtiElements.cache.children[qtiClass]&&QtiElements.cache.children[qtiClass][cacheType])ret=QtiElements.cache.children[qtiClass][cacheType];else{for(let aClass in ret=[],QtiElements.classes){const model=QtiElements.classes[aClass];0<=_.indexOf(model.parents,qtiClass)&&(type?model[type]&&ret.push(aClass):ret.push(aClass),recursive&&(ret=_.union(ret,QtiElements.getChildClasses(aClass,recursive,type))))}QtiElements.cache.children[qtiClass]||(QtiElements.cache.children[qtiClass]={}),QtiElements.cache.children[qtiClass][cacheType]=ret}return ret},isBlock(qtiClass){return QtiElements.is(qtiClass,"block")},isInline(qtiClass){return QtiElements.is(qtiClass,"inline")},is(qtiClass,topClass){if(qtiClass===topClass)return!0;else{const parents=QtiElements.getParentClasses(qtiClass,!0);return 0<=_.indexOf(parents,topClass)}},isVisible(qtiClass){return this.is(qtiClass,"customInteraction")?featuresService.isVisible(`taoQtiItem/creator/customInteraction/${qtiClass.replace(/Interaction$/,"").replace(/^customInteraction\./,"")}`):!this.is(qtiClass,"interaction")||featuresService.isVisible(`taoQtiItem/creator/interaction/${qtiClass.replace(/Interaction$/,"")}`)},getAvailableAuthoringElements(){const tagTitles={commonInteractions:__("Common Interactions"),inlineInteractions:__("Inline Interactions"),graphicInteractions:__("Graphic Interactions")},authoringElements={choiceInteraction:{label:__("Choice Interaction"),description:__("Select a single (radio buttons) or multiple (check boxes) responses among a set of choices."),icon:"icon-choice",short:__("Choice"),qtiClass:"choiceInteraction",tags:[tagTitles.commonInteractions,"mcq"],group:"common-interactions"},orderInteraction:{label:__("Order Interaction"),icon:"icon-order",description:__("Arrange a list of choices in the correct order."),short:__("Order"),qtiClass:"orderInteraction",tags:[tagTitles.commonInteractions,"ordering"],group:"common-interactions"},associateInteraction:{label:__("Associate Interaction"),icon:"icon-associate",description:__("Create pair(s) from a series of choices."),short:__("Associate"),qtiClass:"associateInteraction",tags:[tagTitles.commonInteractions,"association"],group:"common-interactions"},matchInteraction:{label:__("Match Interaction"),icon:"icon-match",description:__("Create association(s) between two sets of choices displayed in a table (row and column)."),short:__("Match"),qtiClass:"matchInteraction",tags:[tagTitles.commonInteractions,"association"],group:"common-interactions"},hottextInteraction:{label:__("Hottext Interaction"),icon:"icon-hottext",description:__("Select one or more text parts (hottext) within a text."),short:__("Hottext"),qtiClass:"hottextInteraction",tags:[tagTitles.commonInteractions,"text"],group:"common-interactions"},gapMatchInteraction:{label:__("Gap Match Interaction"),icon:"icon-gap-match",description:__(" Fill in the gaps in a text from a set of choices."),short:__("Gap Match"),qtiClass:"gapMatchInteraction",tags:[tagTitles.commonInteractions,"text","association"],group:"common-interactions"},sliderInteraction:{label:__("Slider Interaction"),icon:"icon-slider",description:__("Select a value within a numerical range."),short:__("Slider"),qtiClass:"sliderInteraction",tags:[tagTitles.commonInteractions,"special"],group:"common-interactions"},extendedTextInteraction:{label:__("Extended Text Interaction"),icon:"icon-extended-text",description:__("Collect open-ended information in one or more text area(s) (strings or numeric values)."),short:__("Extended Text"),qtiClass:"extendedTextInteraction",tags:[tagTitles.commonInteractions,"text"],group:"common-interactions"},uploadInteraction:{label:__("File Upload Interaction"),icon:"icon-upload",description:__("Upload a file (e.g. document, picture...) as a response."),short:__("File Upload"),qtiClass:"uploadInteraction",tags:[tagTitles.commonInteractions,"special"],group:"common-interactions"},mediaInteraction:{label:__("Media Interaction"),icon:"icon-media",description:__("Control the playing parameters (auto-start, loop) of a video or audio file and report the number of time it has been played."),short:__("Media"),qtiClass:"mediaInteraction",tags:[tagTitles.commonInteractions,"media"],group:"common-interactions"},_container:{label:__("Text Block"),icon:"icon-font",description:__("Block contains the content (stimulus) of the item such as text or image. It is also required for Inline Interactions."),short:__("Block"),qtiClass:"_container",tags:[tagTitles.inlineInteractions,"text"],group:"inline-interactions"},inlineChoiceInteraction:{label:__("Inline Choice Interaction"),icon:"icon-inline-choice",description:__("Select a choice from a drop-down list."),short:__("Inline Choice"),qtiClass:"inlineChoiceInteraction",tags:[tagTitles.inlineInteractions,"inline-interactions","mcq"],group:"inline-interactions"},textEntryInteraction:{label:__("Text Entry Interaction"),icon:"icon-text-entry",description:__("Collect open-ended information in a short text input (strings or numeric values)."),short:__("Text Entry"),qtiClass:"textEntryInteraction",tags:[tagTitles.inlineInteractions,"inline-interactions","text"],group:"inline-interactions"},endAttemptInteraction:{label:__("End Attempt Interaction"),icon:"icon-end-attempt",description:__("Trigger the end of the item attempt."),short:__("End Attempt"),qtiClass:"endAttemptInteraction",tags:[tagTitles.inlineInteractions,"inline-interactions","button","submit"],group:"inline-interactions"},hotspotInteraction:{label:__("Hotspot Interaction"),icon:"icon-hotspot",description:__("Select one or more areas (hotspots) displayed on an picture."),short:__("Hotspot"),qtiClass:"hotspotInteraction",tags:[tagTitles.graphicInteractions,"mcq"],group:"graphic-interactions"},graphicOrderInteraction:{label:__("Graphic Order Interaction"),icon:"icon-graphic-order",description:__("Order the areas (hotspots) displayed on a picture."),short:__("Order"),qtiClass:"graphicOrderInteraction",tags:[tagTitles.graphicInteractions,"ordering"],group:"graphic-interactions"},graphicAssociateInteraction:{label:__("Graphic Associate Interaction"),icon:"icon-graphic-associate",description:__("Create association(s) between areas (hotspots) displayed on a picture."),short:__("Associate"),qtiClass:"graphicAssociateInteraction",tags:[tagTitles.graphicInteractions,"association"],group:"graphic-interactions"},graphicGapMatchInteraction:{label:__("Graphic Gap Match Interaction"),icon:"icon-graphic-gap",description:__("Fill in the gaps on a picture with a set of image choices."),short:__("Gap Match"),qtiClass:"graphicGapMatchInteraction",tags:[tagTitles.graphicInteractions,"association"],group:"graphic-interactions"},selectPointInteraction:{label:__("Select Point Interaction"),icon:"icon-select-point",description:__("Position one or more points on a picture (response areas are not displayed)."),short:__("Select Point"),qtiClass:"selectPointInteraction",tags:[tagTitles.graphicInteractions],group:"graphic-interactions"}},availableElements={};for(const[elementId,element]of Object.entries(authoringElements))this.isVisible(elementId)&&(availableElements[elementId]=element);return availableElements}};return QtiElements}),define("taoQtiItem/portableElementRegistry/factory/ciRegistry",["lodash","i18n","taoQtiItem/portableElementRegistry/factory/factory","taoQtiItem/qtiCreator/helper/qtiElements"],function(_,__,portableElementRegistry,qtiElements){"use strict";return function customInteractionRegistry(){return portableElementRegistry({getAuthoringData(typeIdentifier){let options=1{const execStack=[];return _.forEach(plugins,plugin=>{_.isFunction(plugin[method])&&execStack.push(plugin[method]())}),Promise.all(execStack)},qtiCreatorContext={init(){return pluginLoader.load().then(()=>{const pluginFactories=pluginLoader.getPlugins();return _.forEach(pluginFactories,pluginFactory=>{const plugin=pluginFactory(this);plugins[plugin.getName()]=plugin}),pluginRun("init").then(()=>{this.trigger("init")})}).catch(err=>{this.trigger("error",err)})},destroy(){return pluginRun("destroy").then(()=>{this.trigger("destroy")}).catch(function(err){this.trigger("error",err)})}};return eventifier(qtiCreatorContext)}}),define("taoQtiItem/qtiItem/core/qtiClasses",[],function(){"use strict";var qtiClasses={_container:"taoQtiItem/qtiItem/core/Container",assessmentItem:"taoQtiItem/qtiItem/core/Item",responseProcessing:"taoQtiItem/qtiItem/core/ResponseProcessing",_simpleFeedbackRule:"taoQtiItem/qtiItem/core/response/SimpleFeedbackRule",stylesheet:"taoQtiItem/qtiItem/core/Stylesheet",math:"taoQtiItem/qtiItem/core/Math",figure:"taoQtiItem/qtiItem/core/Figure",img:"taoQtiItem/qtiItem/core/Img",figcaption:"taoQtiItem/qtiItem/core/Figcaption",object:"taoQtiItem/qtiItem/core/Object",outcomeDeclaration:"taoQtiItem/qtiItem/core/variables/OutcomeDeclaration",responseDeclaration:"taoQtiItem/qtiItem/core/variables/ResponseDeclaration",rubricBlock:"taoQtiItem/qtiItem/core/RubricBlock",associableHotspot:"taoQtiItem/qtiItem/core/choices/AssociableHotspot",gap:"taoQtiItem/qtiItem/core/choices/Gap",gapImg:"taoQtiItem/qtiItem/core/choices/GapImg",gapText:"taoQtiItem/qtiItem/core/choices/GapText",hotspotChoice:"taoQtiItem/qtiItem/core/choices/HotspotChoice",hottext:"taoQtiItem/qtiItem/core/choices/Hottext",inlineChoice:"taoQtiItem/qtiItem/core/choices/InlineChoice",simpleAssociableChoice:"taoQtiItem/qtiItem/core/choices/SimpleAssociableChoice",simpleChoice:"taoQtiItem/qtiItem/core/choices/SimpleChoice",associateInteraction:"taoQtiItem/qtiItem/core/interactions/AssociateInteraction",choiceInteraction:"taoQtiItem/qtiItem/core/interactions/ChoiceInteraction",endAttemptInteraction:"taoQtiItem/qtiItem/core/interactions/EndAttemptInteraction",extendedTextInteraction:"taoQtiItem/qtiItem/core/interactions/ExtendedTextInteraction",gapMatchInteraction:"taoQtiItem/qtiItem/core/interactions/GapMatchInteraction",graphicAssociateInteraction:"taoQtiItem/qtiItem/core/interactions/GraphicAssociateInteraction",graphicGapMatchInteraction:"taoQtiItem/qtiItem/core/interactions/GraphicGapMatchInteraction",graphicOrderInteraction:"taoQtiItem/qtiItem/core/interactions/GraphicOrderInteraction",hotspotInteraction:"taoQtiItem/qtiItem/core/interactions/HotspotInteraction",hottextInteraction:"taoQtiItem/qtiItem/core/interactions/HottextInteraction",inlineChoiceInteraction:"taoQtiItem/qtiItem/core/interactions/InlineChoiceInteraction",matchInteraction:"taoQtiItem/qtiItem/core/interactions/MatchInteraction",mediaInteraction:"taoQtiItem/qtiItem/core/interactions/MediaInteraction",orderInteraction:"taoQtiItem/qtiItem/core/interactions/OrderInteraction",prompt:"taoQtiItem/qtiItem/core/interactions/Prompt",selectPointInteraction:"taoQtiItem/qtiItem/core/interactions/SelectPointInteraction",sliderInteraction:"taoQtiItem/qtiItem/core/interactions/SliderInteraction",textEntryInteraction:"taoQtiItem/qtiItem/core/interactions/TextEntryInteraction",uploadInteraction:"taoQtiItem/qtiItem/core/interactions/UploadInteraction",feedbackBlock:"taoQtiItem/qtiItem/core/feedbacks/FeedbackBlock",feedbackInline:"taoQtiItem/qtiItem/core/feedbacks/FeedbackInline",modalFeedback:"taoQtiItem/qtiItem/core/feedbacks/ModalFeedback",customInteraction:"taoQtiItem/qtiItem/core/interactions/CustomInteraction",infoControl:"taoQtiItem/qtiItem/core/PortableInfoControl",include:"taoQtiItem/qtiItem/core/Include",table:"taoQtiItem/qtiItem/core/Table",printedVariable:"taoQtiItem/qtiItem/core/PrintedVariable",_tooltip:"taoQtiItem/qtiItem/core/Tooltip"};return qtiClasses}),define("taoQtiItem/qtiItem/helper/util",["lodash"],function(_){"use strict";_=_&&Object.prototype.hasOwnProperty.call(_,"default")?_["default"]:_;var util={buildSerial:function buildSerial(prefix){for(var id=prefix||"",chars="abcdefghijklmnopqrstuvwxyz0123456789",i=0;22>i;i++)id+=chars.charAt(Math.floor(Math.random()*chars.length));return id},buildId:function buildId(item,prefix){var i=1,suffix="",exists=!1,id,usedIds;if(!item)throw new TypeError("A item is required to generate a unique identifier");usedIds=item.getUsedIds();do exists=!1,id=prefix+suffix,_.contains(usedIds,id)&&(exists=!0,suffix="_"+i,i++);while(exists);return id},buildIdentifier:function buildIdentifier(item,prefix,useSuffix){var suffix="",i=1,exists=!1,id,usedIds;if(!item)throw new TypeError("A item is required to generate a unique identifier");if(!prefix)throw new TypeError("Prefix is required to build an identifier");usedIds=item.getUsedIdentifiers(),useSuffix=!!_.isUndefined(useSuffix)||useSuffix,prefix&&(prefix=prefix.replace(/_[0-9]+$/gi,"_").replace(/[^a-zA-Z0-9_]/gi,"_").replace(/(_)+/gi,"_"),useSuffix&&(suffix="_"+i));do exists=!1,id=prefix+suffix,usedIds[id]&&(exists=!0,suffix="_"+i,i++);while(exists);return id},findInCollection:function findInCollection(element,collectionNames,searchedSerial){var found=null;if(_.isString(collectionNames)&&(collectionNames=[collectionNames]),_.isArray(collectionNames))_.each(collectionNames,function(collectionName){var collection=element;_.each(collectionName.split("."),function(nameToken){collection=collection[nameToken]});var elt=collection[searchedSerial];return elt?(found={parent:element,element:elt},!1):(_.each(collection,function(elt){if(_.isFunction(elt.find)&&(found=elt.find(searchedSerial),found))return!1}),!found)&&void 0});else throw new Error("invalid argument : collectionNames must be an array or a string");return found},addMarkupNamespace:function addMarkupNamespace(markup,ns){return ns?(markup=markup.replace(/<(\/)?([a-z:]+)(\s?)([^><]*)>/g,function($0,$1,$2,$3,$4){return 0<$2.indexOf(":")?$0:($1=$1||"",$3=$3||"","<"+$1+ns+":"+$2+$3+$4+">")}),markup):markup},removeMarkupNamespaces:function removeMarkupNamespace(markup){return markup.replace(/<(\/)?(\w*):([^>]*)>/g,"<$1$3>")},getMarkupUsedNamespaces:function getMarkupUsedNamespaces(markup){var namespaces=[];return markup.replace(/<(\/)?(\w*):([^>]*)>/g,function(original,slash,ns,node){return namespaces.push(ns),"<"+slash+node+">"}),_.uniq(namespaces)}};return util}),define("taoQtiItem/qtiItem/helper/rendererConfig",["lodash","jquery"],function(_,$){"use strict";_=_&&Object.prototype.hasOwnProperty.call(_,"default")?_["default"]:_,$=$&&Object.prototype.hasOwnProperty.call($,"default")?$["default"]:$;var rendererConfigHelper={getOptionsFromArguments:function(args){var options={data:{},placeholder:null,subclass:"",renderer:null};return _.each(args,function(arg){arg&&(arg.isRenderer?options.renderer=arg:arg instanceof $&&arg.length?options.placeholder=arg:_.isString(arg)?options.subclass=arg:_.isPlainObject(arg)?options.data=arg:console.log("invalid arg",arg,args))}),options}};return rendererConfigHelper}),define("taoQtiItem/qtiItem/core/Element",["jquery","lodash","class","core/logger","taoQtiItem/qtiItem/helper/util","taoQtiItem/qtiItem/helper/rendererConfig"],function($,_,_class,loggerFactory,util,rendererConfig){"use strict";$=$&&Object.prototype.hasOwnProperty.call($,"default")?$["default"]:$,_=_&&Object.prototype.hasOwnProperty.call(_,"default")?_["default"]:_,loggerFactory=loggerFactory&&Object.prototype.hasOwnProperty.call(loggerFactory,"default")?loggerFactory["default"]:loggerFactory,util=util&&Object.prototype.hasOwnProperty.call(util,"default")?util["default"]:util,rendererConfig=rendererConfig&&Object.prototype.hasOwnProperty.call(rendererConfig,"default")?rendererConfig["default"]:rendererConfig;var _instances={},logger=loggerFactory("taoQtiItem/qtiItem/core/Element"),Element=Class.extend({qtiClass:"",serial:"",rootElement:null,init:function(serial,attributes){if(this.attributes={},this.metaData={},"object"==typeof serial&&(attributes=serial,serial=""),serial||(serial=util.buildSerial(this.qtiClass+"_")),serial&&("string"!=typeof serial||!serial.match(/^[a-z_0-9]*$/i)))throw"invalid QTI serial : ("+typeof serial+") "+serial;if(!_instances[serial])_instances[serial]=this,this.serial=serial,this.setAttributes(attributes||{});else throw"a QTI Element with the same serial already exists "+serial;"function"==typeof this.initContainer&&this.initContainer(arguments[2]||""),"function"==typeof this.initObject&&this.initObject()},is:function(qtiClass){return qtiClass===this.qtiClass},placeholder:function(){return"{{"+this.serial+"}}"},getSerial:function(){return this.serial},getUsedIdentifiers:function(){var usedIds={},elts=this.getComposingElements();for(var i in elts){var elt=elts[i],id=elt.attr("identifier");id&&(usedIds[id]=elt)}return usedIds},getUsedIds:function getUsedIds(){var usedIds=[];return _.forEach(this.getComposingElements(),function(elt){var id=elt.attr("id");id&&!_.contains(usedIds,id)&&usedIds.push(id)}),usedIds},attr:function(name,value){if(name)if(void 0!==value)this.attributes[name]=value;else if("object"==typeof name)for(var prop in name)this.attr(prop,name[prop]);else if("string"==typeof name)return void 0===this.attributes[name]?void 0:this.attributes[name];return this},data:function(name,value){if(name)if(void 0!==value)this.metaData[name]=value,$(document).trigger("metaChange.qti-widget",{element:this,key:name,value:value});else if("object"==typeof name)for(var prop in name)this.data(prop,name[prop]);else if("string"==typeof name)return void 0===this.metaData[name]?void 0:this.metaData[name];return this},removeData:function(name){return delete this.metaData[name],this},removeAttr:function(name){return this.removeAttributes(name)},setAttributes:function(attributes){return _.isPlainObject(attributes)||logger.warn("attributes should be a plain object"),this.attributes=attributes,this},getAttributes:function(){return _.clone(this.attributes)},removeAttributes:function(attrNames){for(var i in"string"==typeof attrNames&&(attrNames=[attrNames]),attrNames)delete this.attributes[attrNames[i]];return this},getComposingElements:function(){function append(element){elts[element.getSerial()]=element,elts=_.extend(elts,element.getComposingElements())}var elts={};return"function"==typeof this.initContainer&&append(this.getBody()),"function"==typeof this.initObject&&append(this.getObject()),_.each(this.metaData,function(v){Element.isA(v,"_container")?append(v):_.isArray(v)&&_.each(v,function(v){Element.isA(v,"_container")&&append(v)})}),elts},getUsedClasses:function(){var ret=[this.qtiClass],composingElts=this.getComposingElements();return _.each(composingElts,function(elt){ret.push(elt.qtiClass)}),_.uniq(ret)},find:function(serial){var found=null,object,body;return"function"==typeof this.initObject&&(object=this.getObject(),object.serial===serial&&(found={parent:this,element:object,location:"object"})),found||"function"!=typeof this.initContainer||(body=this.getBody(),found=body.serial===serial?{parent:this,element:body,location:"body"}:this.getBody().find(serial,this)),found},parent:function(){var item=this.getRootElement();if(item){var found=item.find(this.getSerial());if(found)return found.parent}return null},setRelatedItem:function(item){logger.warn("Deprecated use of setRelatedItem()"),this.setRootElement(item)},setRootElement:function(item){var composingElts,i;if(Element.isA(item,"assessmentItem"))for(i in this.rootElement=item,composingElts=this.getComposingElements(),composingElts)composingElts[i].setRootElement(item)},getRelatedItem:function(){return logger.warn("Deprecated use of getRelatedItem()"),this.getRootElement()},getRootElement:function(){var ret=null;return Element.isA(this.rootElement,"assessmentItem")&&(ret=this.rootElement),ret},setRenderer:function(renderer){if(renderer&&renderer.isRenderer){this.renderer=renderer;var elts=this.getComposingElements();for(var serial in elts)elts[serial].setRenderer(renderer)}else throw"invalid qti rendering engine"},getRenderer:function(){return this.renderer},render:function render(){var args=rendererConfig.getOptionsFromArguments(arguments),_renderer=args.renderer||this.getRenderer(),tplData={},defaultData={tag:this.qtiClass,serial:this.serial,attributes:this.getAttributes()},rendering;if(!_renderer)throw new Error("render: no renderer found for the element "+this.qtiClass+":"+this.serial);return"function"==typeof this.initContainer&&(defaultData.body=this.getBody().render(args.renderer)),"function"==typeof this.initObject&&(defaultData.object={attributes:this.object.getAttributes()},defaultData.object.attributes.data=_renderer.resolveUrl(this.object.attr("data"))),tplData=_.merge(defaultData,args.data||{}),tplData=_renderer.getData(this,tplData,args.subclass),rendering=_renderer.renderTpl(this,tplData,args.subclass),args.placeholder&&args.placeholder.replaceWith(rendering),rendering},postRender:function(data,altClassName,renderer){var postRenderers=[],_renderer=renderer||this.getRenderer();if("function"==typeof this.initContainer&&(postRenderers=this.getBody().postRender(data,"",renderer)),_renderer)postRenderers.push(_renderer.postRender(this,data,altClassName));else throw"postRender: no renderer found for the element "+this.qtiClass+":"+this.serial;return _.compact(postRenderers)},getContainer:function($scope,subclass){var renderer=this.getRenderer();if(renderer)return renderer.getContainer(this,$scope,subclass);throw"getContainer: no renderer found for the element "+this.qtiClass+":"+this.serial},toArray:function(){var arr={serial:this.serial,type:this.qtiClass,attributes:this.getAttributes()};return"function"==typeof this.initContainer&&(arr.body=this.getBody().toArray()),"function"==typeof this.initObject&&(arr.object=this.object.toArray()),arr},isEmpty:function(){return!1},addClass:function(className){var clazz=this.attr("class")||"";_containClass(clazz,className)||this.attr("class",clazz+(clazz.length?" ":"")+className)},hasClass:function(className){return _containClass(this.attr("class"),className)},removeClass:function(className){var clazz=this.attr("class")||"";if(clazz){var regex=new RegExp("(?:^|\\s)"+className+"(?:\\s|$)");clazz=clazz.replace(regex," ").trim(),clazz?this.attr("class",clazz):this.removeAttr("class")}},toggleClass:function(className,state){return"boolean"==typeof state?state?this.addClass(className):this.removeClass(className):this.hasClass(className)?this.removeClass(className):this.addClass(className)},isset:function(){return Element.issetElement(this.serial)},unset:function(){return Element.unsetElement(this.serial)}}),_containClass=function(allClassStr,className){var regex=new RegExp("(?:^|\\s)"+className+"(?:\\s|$)","");return allClassStr&®ex.test(allClassStr)};return Element.isA=function(qtiElement,qtiClass){return qtiElement instanceof Element&&qtiElement.is(qtiClass)},Element.getElementBySerial=function(serial){return _instances[serial]},Element.issetElement=function(serial){return!!_instances[serial]},Element.unsetElement=function(serial){var element=Element.getElementBySerial(serial);if(element){var composingElements=element.getComposingElements();return _.each(composingElements,function(elt){delete _instances[elt.serial]}),delete _instances[element.serial],!0}return!1},Element}),define("taoQtiItem/qtiItem/helper/xmlNsHandler",[],function(){"use strict";function getPrefix(namespaces,html5Ns){let key;for(key in namespaces)if(namespaces[key]===html5Ns)return key;return"qh5"}const prefixed="article|aside|bdi|figure|footer|header|nav|rb|rp|rt|rtc|ruby|section";var xmlNsHandler={stripNs:function stripNs(body){const pattern="([\\w]+)\\:(article|aside|bdi|figure|footer|header|nav|rb|rp|rt|rtc|ruby|section)",openRegEx=/(<([\w]+)\:(article|aside|bdi|figure|footer|header|nav|rb|rp|rt|rtc|ruby|section))/gi,closeRegEx=/(<\/([\w]+)\:(article|aside|bdi|figure|footer|header|nav|rb|rp|rt|rtc|ruby|section)>)/gi;return body.replace(openRegEx,"<$3").replace(closeRegEx,"")},restoreNs:function restoreNs(xml,namespaces){let ignoreMarkup=!!(2)+)/gim,""));const xmlRe=/(<(article|aside|bdi|figure|footer|header|nav|rb|rp|rt|rtc|ruby|section)[^>]*>|<\/(article|aside|bdi|figure|footer|header|nav|rb|rp|rt|rtc|ruby|section)>)/gi,tagRe=/((<)(article|aside|bdi|figure|footer|header|nav|rb|rp|rt|rtc|ruby|section)([^>]*)(>)|(<\/)(article|aside|bdi|figure|footer|header|nav|rb|rp|rt|rtc|ruby|section)(>))/i,xmlMatch=xmlCopy.match(xmlRe),imsXsd="http://www.imsglobal.org/xsd",html5Ns=imsXsd+"/imsqtiv2p2_html5_v1p0",prefix=getPrefix(namespaces,html5Ns),prefixAtt="xmlns:"+prefix+"=\""+html5Ns+"\"";let i=xmlMatch?xmlMatch.length:0;if(!xmlMatch)return xml;for(;i--;){const tagMatch=xmlMatch[i].match(tagRe);xml=xml.replace(xmlMatch[i],tagMatch[5]?"<"+prefix+":"+tagMatch[3]+tagMatch[4]+">":"")}return xmlMatch.length&&-1===xml.indexOf(prefixAtt)&&(xml=xml.replace("({qtiClass:"responseCondition",responseIf:{qtiClass:"responseIf",expression:{qtiClass:"match",expressions:[{qtiClass:"variable",attributes:{identifier:responseIdentifier}},{qtiClass:"correct",attributes:{identifier:responseIdentifier}}]},responseRules:[{qtiClass:"setOutcomeValue",attributes:{identifier:outcomeIdentifier},expression:{qtiClass:"sum",expressions:[{qtiClass:"variable",attributes:{identifier:outcomeIdentifier}},{qtiClass:"baseValue",attributes:{baseType:"integer"},value:"1"}]}}]}}),MAP_RESPONSE:(responseIdentifier,outcomeIdentifier)=>({qtiClass:"responseCondition",responseIf:{qtiClass:"responseIf",expression:{qtiClass:"not",expressions:[{qtiClass:"isNull",expressions:[{qtiClass:"variable",attributes:{identifier:responseIdentifier}}]}]},responseRules:[{qtiClass:"setOutcomeValue",attributes:{identifier:outcomeIdentifier},expression:{qtiClass:"sum",expressions:[{qtiClass:"variable",attributes:{identifier:outcomeIdentifier}},{qtiClass:"mapResponse",attributes:{identifier:responseIdentifier}}]}}]}}),MAP_RESPONSE_POINT:(responseIdentifier,outcomeIdentifier)=>({qtiClass:"responseCondition",responseIf:{qtiClass:"responseIf",expression:{qtiClass:"not",expressions:[{qtiClass:"isNull",expressions:[{qtiClass:"variable",attributes:{identifier:responseIdentifier}}]}]},responseRules:[{qtiClass:"setOutcomeValue",attributes:{identifier:outcomeIdentifier},expression:{qtiClass:"sum",expressions:[{qtiClass:"variable",attributes:{identifier:outcomeIdentifier}},{qtiClass:"mapResponsePoint",attributes:{identifier:responseIdentifier}}]}}]}})};return responseRules}),define("taoQtiItem/qtiItem/helper/response",["lodash","taoQtiItem/qtiItem/helper/responseRules"],function(_,responseRulesHelper){"use strict";_=_&&Object.prototype.hasOwnProperty.call(_,"default")?_["default"]:_,responseRulesHelper=responseRulesHelper&&Object.prototype.hasOwnProperty.call(responseRulesHelper,"default")?responseRulesHelper["default"]:responseRulesHelper;const _templateNames={MATCH_CORRECT:"http://www.imsglobal.org/question/qti_v2p1/rptemplates/match_correct",MAP_RESPONSE:"http://www.imsglobal.org/question/qti_v2p1/rptemplates/map_response",MAP_RESPONSE_POINT:"http://www.imsglobal.org/question/qti_v2p1/rptemplates/map_response_point",NONE:"no_response_processing"};var response={isUsingTemplate(response,tpl){return!!(_.isString(tpl)&&(tpl===response.template||_templateNames[tpl]===response.template))},isValidTemplateName(tplName){return!!this.getTemplateUriFromName(tplName)},getTemplateUriFromName(tplName){return _templateNames[tplName]||""},getTemplateNameFromUri(tplUri){let tplName="";return _.forIn(_templateNames,(uri,name)=>{if(uri===tplUri)return tplName=name,!1}),tplName},getTemplateNameFromResponseRules(responseIdentifier,responseRules){if(!responseRules)return"NONE";const{responseIf:{responseRules:[outcomeRules={}]=[]}={}}=responseRules,{attributes:{identifier:outcomeIdentifier}={}}=outcomeRules;return outcomeIdentifier?Object.keys(responseRulesHelper).find(key=>_.isEqual(responseRules,responseRulesHelper[key](responseIdentifier,outcomeIdentifier))):""}};return response}),define("taoQtiItem/qtiItem/helper/itemScore",[],function(){"use strict";var itemScore=responseIdentifiers=>{const outcomeExpressions=responseIdentifiers.map(outcomeIdentifier=>({qtiClass:"variable",attributes:{identifier:`SCORE_${outcomeIdentifier}`}}));return{qtiClass:"setOutcomeValue",attributes:{identifier:"SCORE"},expression:{qtiClass:"sum",expressions:outcomeExpressions}}};return itemScore}),define("taoQtiItem/qtiItem/core/Loader",["lodash","class","taoQtiItem/qtiItem/core/qtiClasses","taoQtiItem/qtiItem/core/Element","taoQtiItem/qtiItem/helper/xmlNsHandler","core/moduleLoader","taoQtiItem/qtiItem/helper/response","taoQtiItem/qtiItem/helper/itemScore"],function(_,_class,qtiClasses,Element,xmlNsHandler,moduleLoader,responseHelper,itemScoreHelper){"use strict";_=_&&Object.prototype.hasOwnProperty.call(_,"default")?_["default"]:_,qtiClasses=qtiClasses&&Object.prototype.hasOwnProperty.call(qtiClasses,"default")?qtiClasses["default"]:qtiClasses,Element=Element&&Object.prototype.hasOwnProperty.call(Element,"default")?Element["default"]:Element,xmlNsHandler=xmlNsHandler&&Object.prototype.hasOwnProperty.call(xmlNsHandler,"default")?xmlNsHandler["default"]:xmlNsHandler,moduleLoader=moduleLoader&&Object.prototype.hasOwnProperty.call(moduleLoader,"default")?moduleLoader["default"]:moduleLoader,responseHelper=responseHelper&&Object.prototype.hasOwnProperty.call(responseHelper,"default")?responseHelper["default"]:responseHelper,itemScoreHelper=itemScoreHelper&&Object.prototype.hasOwnProperty.call(itemScoreHelper,"default")?itemScoreHelper["default"]:itemScoreHelper;const loadPortableCustomElementProperties=(portableElement,rawProperties)=>{var properties={};_.forOwn(rawProperties,(value,key)=>{try{properties[key]=JSON.parse(value)}catch(e){properties[key]=value}}),portableElement.properties=properties},loadPortableCustomElementData=(portableElement,data)=>{portableElement.typeIdentifier=data.typeIdentifier,portableElement.markup=data.markup,portableElement.entryPoint=data.entryPoint,portableElement.libraries=data.libraries,portableElement.setNamespace("",data.xmlns),loadPortableCustomElementProperties(portableElement,data.properties)};var Loader=Class.extend({init(item,classesLocation){this.qti={},this.classesLocation={},this.item=item||null,this.setClassesLocation(classesLocation||qtiClasses)},setClassesLocation(qtiClassesList){return _.extend(this.classesLocation,qtiClassesList),this},getRequiredClasses(data){let ret=[];for(let i in data)"qtiClass"==i&&"_container"!==data[i]&&"rootElement"!==i?ret.push(data[i]):"object"==typeof data[i]&&"responseRules"!==i&&(ret=_.union(ret,this.getRequiredClasses(data[i])));return ret},loadRequiredClasses(data,callback,reload){let requiredClass;const requiredClasses=this.getRequiredClasses(data,reload),required=[];for(let i in requiredClasses)if(requiredClass=requiredClasses[i],this.classesLocation[requiredClass])required.push({module:this.classesLocation[requiredClass],category:"qti"});else throw new Error(`missing qti class location declaration : ${requiredClass}`);moduleLoader([],()=>!0).addList(required).load().then(loadeded=>{loadeded.forEach(QtiClass=>{this.qti[QtiClass.prototype.qtiClass]=QtiClass}),callback.call(this,this.qti)})},getLoadedClasses(){return _.keys(this.qti)},loadItemData(data,callback){this.loadRequiredClasses(data,Qti=>{if("object"==typeof data&&"assessmentItem"===data.qtiClass){for(let i in data.serial&&Element.unsetElement(data.serial),this.item=new Qti.assessmentItem(data.serial,data.attributes||{}),this.loadContainer(this.item.getBody(),data.body),data.outcomes){const outcome=this.buildOutcome(data.outcomes[i]);outcome&&this.item.addOutcomeDeclaration(outcome)}for(let i in data.feedbacks){const feedback=this.buildElement(data.feedbacks[i]);feedback&&this.item.addModalFeedback(feedback)}for(let i in data.stylesheets){const stylesheet=this.buildElement(data.stylesheets[i]);stylesheet&&this.item.addStylesheet(stylesheet)}let responseRules=data.responseProcessing&&data.responseProcessing.responseRules?[...data.responseProcessing.responseRules]:[];for(let i in data.responses){const responseIdentifier=data.responses[i].identifier,responseRuleItemIndex=responseRules.findIndex(_ref=>{let{responseIf:{expression:{expressions:[expression={}]=[]}={}}={}}=_ref;return expression.attributes&&expression.attributes.identifier===responseIdentifier||expression.expressions&&expression.expressions[0]&&expression.expressions[0].attributes&&expression.expressions[0].attributes.identifier===responseIdentifier}),[responseRule]=-1===responseRuleItemIndex?[]:responseRules.splice(responseRuleItemIndex,1),response=this.buildResponse(data.responses[i],responseRule);if(response){this.item.addResponseDeclaration(response);const feedbackRules=data.responses[i].feedbackRules;feedbackRules&&_.forIn(feedbackRules,(fbData,serial)=>{const{attributes:{identifier:feedbackOutcomeIdentifier}={}}=data.outcomes[fbData.feedbackOutcome]||{};response.feedbackRules[serial]=this.buildSimpleFeedbackRule(fbData,response);const feedbackResponseRuleIndex=responseRules.findIndex(_ref2=>{let{responseIf:{responseRules:[setOutcomeResponseRule={}]=[]}={}}=_ref2;const{attributes={},qtiClass}=setOutcomeResponseRule,outcomeIdentifier=attributes.identifier;return feedbackOutcomeIdentifier===outcomeIdentifier&&"setOutcomeValue"===qtiClass});-1!==feedbackResponseRuleIndex&&responseRules.splice(feedbackResponseRuleIndex,1)})}}const responseIdentifiers=Object.keys(this.item.responses||{}).map(responseKey=>this.item.responses[responseKey].attributes.identifier);if(data.responseProcessing){const customResponseProcessing=0!this.item.responses[responseKey].template);this.item.setResponseProcessing(this.buildResponseProcessing(data.responseProcessing,customResponseProcessing))}this.item.setNamespaces(data.namespaces),this.item.setSchemaLocations(data.schemaLocations),this.item.setApipAccessibility(data.apipAccessibility)}"function"==typeof callback&&callback.call(this,this.item)})},loadAndBuildElement(data,callback){this.loadRequiredClasses(data,()=>{const element=this.buildElement(data);"function"==typeof callback&&callback.call(this,element)})},loadElement(element,data,callback){this.loadRequiredClasses(data,()=>{this.loadElementData(element,data),"function"==typeof callback&&callback.call(this,element)})},loadElements(data,callback){if(!this.item)throw new Error("QtiLoader : cannot load elements in empty item");this.loadRequiredClasses(data,()=>{const allElements=this.item.getComposingElements();for(let i in data){const elementData=data[i];elementData&&elementData.qtiClass&&elementData.serial&&allElements[elementData.serial]&&this.loadElementData(allElements[elementData.serial],elementData)}"function"==typeof callback&&callback.call(this,this.item)})},buildResponse(data,responseRule){const response=this.buildElement(data);return response.template=responseHelper.getTemplateUriFromName(responseHelper.getTemplateNameFromResponseRules(data.identifier,responseRule))||data.howMatch||null,response.defaultValue=data.defaultValue||null,response.correctResponse=data.correctResponses||null,response.mapEntries=_.size(data.mapping)?data.mapping:_.size(data.areaMapping)?data.areaMapping:{},response.mappingAttributes=data.mappingAttributes||{},response},buildSimpleFeedbackRule(data,response){const feedbackRule=this.buildElement(data);feedbackRule.setCondition(response,data.condition,data.comparedValue||null),feedbackRule.feedbackOutcome=this.item.outcomes[data.feedbackOutcome]||null,feedbackRule.feedbackThen=this.item.modalFeedbacks[data.feedbackThen]||null,feedbackRule.feedbackElse=this.item.modalFeedbacks[data.feedbackElse]||null;const comparedOutcome=feedbackRule.comparedOutcome;return feedbackRule.feedbackThen&&feedbackRule.feedbackThen.data("relatedResponse",comparedOutcome),feedbackRule.feedbackElse&&feedbackRule.feedbackElse.data("relatedResponse",comparedOutcome),feedbackRule},buildOutcome(data){const outcome=this.buildElement(data);return outcome.defaultValue=data.defaultValue||null,outcome},buildResponseProcessing(data,customResponseProcessing){const rp=this.buildElement(data);return customResponseProcessing?(rp.xml=data.data,rp.processingType="custom"):rp.processingType="templateDriven",rp},loadContainer(bodyObject,bodyData){if(!Element.isA(bodyObject,"_container"))throw new Error("bodyObject must be a QTI Container");if(!(bodyData&&"string"==typeof bodyData.body&&"object"==typeof bodyData.elements))throw new Error("wrong bodydata format");const attributes=_.defaults(bodyData.attributes||{},bodyObject.attributes||{});for(let serial in bodyObject.setAttributes(attributes),bodyData.elements){const eltData=bodyData.elements[serial],element=this.buildElement(eltData);element&&bodyObject.setElement(element,bodyData.body)}bodyObject.body(xmlNsHandler.stripNs(bodyData.body))},buildElement(elementData){if(!(elementData&&elementData.qtiClass&&elementData.serial))throw new Error("wrong elementData format");const className=elementData.qtiClass;if(!this.qti[className])throw new Error(`the qti element class does not exist: ${className}`);const elt=new this.qti[className](elementData.serial);return this.loadElementData(elt,elementData),elt},loadElementData(element,data){const attributes=_.defaults(data.attributes||{},element.attributes||{});element.setAttributes(attributes);let body=data.body;return!body&&data.text&&"inlineChoice"===data.qtiClass&&(body={body:data.text,elements:{}}),element.body&&body&&element.bdy&&this.loadContainer(element.getBody(),body),element.object&&data.object&&element.object&&this.loadObjectData(element.object,data.object),Element.isA(element,"interaction")?this.loadInteractionData(element,data):Element.isA(element,"choice")?this.loadChoiceData(element,data):Element.isA(element,"math")?this.loadMathData(element,data):Element.isA(element,"infoControl")?this.loadPicData(element,data):Element.isA(element,"_tooltip")&&this.loadTooltipData(element,data),element},loadInteractionData(interaction,data){Element.isA(interaction,"blockInteraction")&&data.prompt&&this.loadContainer(interaction.prompt.getBody(),data.prompt),this.buildInteractionChoices(interaction,data),Element.isA(interaction,"customInteraction")&&this.loadPciData(interaction,data)},buildInteractionChoices(interaction,data){if(data.choices){if(Element.isA(interaction,"matchInteraction"))for(let set=0;2>set;set++){if(!data.choices[set])throw new Error(`missing match set #${set}`);const matchSet=data.choices[set];for(let serial in matchSet){const choice=this.buildElement(matchSet[serial]);choice&&interaction.addChoice(choice,set)}}else for(let serial in data.choices){const choice=this.buildElement(data.choices[serial]);choice&&interaction.addChoice(choice)}if(Element.isA(interaction,"graphicGapMatchInteraction")&&data.gapImgs)for(let serial in data.gapImgs){const gapImg=this.buildElement(data.gapImgs[serial]);gapImg&&interaction.addGapImg(gapImg)}}},loadChoiceData(choice,data){if(Element.isA(choice,"textVariableChoice"))choice.val(data.text);else if(Element.isA(choice,"gapImg"));else if(Element.isA(choice,"gapText"))choice.body()||choice.body(data.text);else if(Element.isA(choice,"containerChoice"));},loadObjectData(object,data){object.setAttributes(data.attributes),data._alt&&("object"===data._alt.qtiClass?object._alt=Loader.buildElement(data._alt):object._alt=data._alt)},loadMathData(math,data){math.ns=data.ns||{},math.setMathML(data.mathML||""),_.forIn(data.annotations||{},(value,encoding)=>{math.setAnnotation(encoding,value)})},loadTooltipData(tooltip,data){tooltip.content(data.content)},loadPciData(pci,data){loadPortableCustomElementData(pci,data)},loadPicData(pic,data){loadPortableCustomElementData(pic,data)}});return Loader}),define("taoQtiItem/qtiCreator/model/helper/event",["jquery","lodash"],function($,_){"use strict";var namespace=".qti-creator",namespaceModel=".qti-creator",eventList=["containerBodyChange","containerElementAdded","elementCreated.qti-widget","attributeChange.qti-widget","choiceCreated.qti-widget","correctResponseChange.qti-widget","mapEntryChange.qti-widget","mapEntryRemove.qti-widget","deleted.qti-widget","choiceTextChange.qti-widget","responseTemplateChange.qti-widget","mappingAttributeChange.qti-widget","feedbackRuleConditionChange.qti-widget","feedbackRuleCreated.qti-widget","feedbackRuleRemoved.qti-widget","feedbackRuleElseCreated.qti-widget","feedbackRuleElseRemoved.qti-widget"],event={choiceCreated:function choiceCreated(choice,interaction){$(document).trigger("choiceCreated.qti-widget",{choice:choice,interaction:interaction})},choiceDeleted:function choiceDeleted(choice,interaction){$(document).trigger("choiceDeleted.qti-widget",{choice:choice,interaction:interaction})},deleted:function(element,parent){element.isset()&&element.unset(),$(document).off("."+element.getSerial()),$(document).trigger("deleted.qti-widget",{element:element,parent:parent})},getList:function(addedNamespace){var events=_.clone(eventList);return addedNamespace?_.map(events,function(e){return e+"."+addedNamespace}):events},initElementToWidgetListeners:function(){var ns=".widget-container";$(document).off(".widget-container").on(event.getList(".widget-container").join(" "),function(e,data){var element=data.element||data.container||null,widget=data&&element&&element.data("widget");!widget&&data.parent&&(element=data.parent,widget=element.data("widget")),widget&&widget.$container.trigger(e.type+".qti-creator"+namespaceModel,data)})},getNs:function(){return".qti-creator"},getNsModel:function(){return namespaceModel}};return event}),define("taoQtiItem/qtiCreator/model/helper/invalidator",["lodash"],function(_){"use strict";const invalidator={completelyValid:function(element){const item=element.getRootElement();if(item){const serial=element.getSerial(),invalidElements=item.data("invalid")||{};delete invalidElements[serial],item.data("invalid",invalidElements)}},valid:function(element,key){const item=element.getRootElement(),serial=element.getSerial();if(item){const invalidElements=item.data("invalid")||{};if(key)invalidElements[serial]&&invalidElements[serial][key]&&(delete invalidElements[serial][key],!_.size(invalidElements[serial])&&delete invalidElements[serial],item.data("invalid",invalidElements));else throw new Error("missing required argument \"key\"")}},invalid:function(element,key,message,stateName){const item=element.getRootElement(),serial=element.getSerial();if(item){const invalidElements=item.data("invalid")||{};if(key)invalidElements[serial]||(invalidElements[serial]={}),invalidElements[serial][key]={message:message||"",stateName:stateName||"active"},item.data("invalid",invalidElements);else throw new Error("missing required arguments \"key\"")}},isValid:function(element,key){const item=element.getRootElement(),serial=element.getSerial();if(item){const invalidElements=item.data("invalid")||{};return key?!(invalidElements[serial]&&invalidElements[serial][key]):!invalidElements[serial]}return!0}};return invalidator}),define("taoQtiItem/qtiCreator/model/mixin/editable",["lodash","jquery","core/encoder/entity","taoQtiItem/qtiItem/core/Element","taoQtiItem/qtiCreator/model/helper/event","taoQtiItem/qtiCreator/model/helper/invalidator"],function(_,$,entity,Element,event,invalidator){"use strict";const _removeSelf=function(element){let removed=!1;const related=element.getRootElement();if(related){const found=related.find(element.getSerial());if(found){const parent=found.parent;if(element.getResponseDeclaration){const response=element.getResponseDeclaration();response&&(invalidator.completelyValid(response),Element.unsetElement(response))}Element.isA(parent,"interaction")?("gapImg"===element.qtiClass?parent.removeGapImg(element):Element.isA(element,"choice")&&parent.removeChoice(element),removed=!0):"body"===found.location&&_.isFunction(parent.initContainer)?(_.isFunction(element.beforeRemove)&&element.beforeRemove(),parent.getBody().removeElement(element),removed=!0):Element.isA(parent,"_container")&&(_.isFunction(element.beforeRemove)&&element.beforeRemove(),parent.removeElement(element),removed=!0),removed&&(element.data("removed",!0),invalidator.completelyValid(element),event.deleted(element,parent))}}else throw new Error("no related item found");return removed},_removeElement=function(element,containerPropName,eltToBeRemoved){let targetSerial="",targetElt;return element[containerPropName]&&("string"==typeof eltToBeRemoved?(targetSerial=eltToBeRemoved,targetElt=Element.getElementBySerial(targetSerial)):eltToBeRemoved instanceof Element&&(targetSerial=eltToBeRemoved.getSerial(),targetElt=eltToBeRemoved),targetSerial&&(invalidator.completelyValid(targetElt),delete element[containerPropName][targetSerial],Element.unsetElement(targetSerial))),element},methods={init:function(serial,attributes){const attr={};"object"==typeof serial&&(attributes=serial,serial=""),_.isFunction(this.getDefaultAttributes)&&_.extend(attr,this.getDefaultAttributes()),_.extend(attr,attributes),this._super(serial,attr)},attr:function(key,value){const ret=this._super(key,value);return"undefined"!=typeof key&&"undefined"!=typeof value&&$(document).trigger("attributeChange.qti-widget",{element:this,key:key,value:entity.encode(value)}),_.isString(ret)?entity.decode(ret):ret},removeAttr:function(key){const ret=this._super(key);return $(document).trigger("attributeChange.qti-widget",{element:this,key:key,value:null}),ret},remove:function(){if(0===arguments.length)return _removeSelf(this);if(2===arguments.length)return _removeElement(this,arguments[0],arguments[1]);throw new Error("invalid number of argument given")}};return methods}),define("taoQtiItem/qtiCreator/model/qtiClasses",["lodash","taoQtiItem/qtiItem/core/qtiClasses"],function(_,qtiClasses){"use strict";return _.defaults({assessmentItem:"taoQtiItem/qtiCreator/model/Item",_container:"taoQtiItem/qtiCreator/model/Container",figure:"taoQtiItem/qtiCreator/model/Figure",img:"taoQtiItem/qtiCreator/model/Img",figcaption:"taoQtiItem/qtiCreator/model/Figcaption",math:"taoQtiItem/qtiCreator/model/Math",object:"taoQtiItem/qtiCreator/model/Object",table:"taoQtiItem/qtiCreator/model/Table",rubricBlock:"taoQtiItem/qtiCreator/model/RubricBlock",modalFeedback:"taoQtiItem/qtiCreator/model/feedbacks/ModalFeedback",choiceInteraction:"taoQtiItem/qtiCreator/model/interactions/ChoiceInteraction",orderInteraction:"taoQtiItem/qtiCreator/model/interactions/OrderInteraction",associateInteraction:"taoQtiItem/qtiCreator/model/interactions/AssociateInteraction",matchInteraction:"taoQtiItem/qtiCreator/model/interactions/MatchInteraction",inlineChoiceInteraction:"taoQtiItem/qtiCreator/model/interactions/InlineChoiceInteraction",simpleChoice:"taoQtiItem/qtiCreator/model/choices/SimpleChoice",simpleAssociableChoice:"taoQtiItem/qtiCreator/model/choices/SimpleAssociableChoice",inlineChoice:"taoQtiItem/qtiCreator/model/choices/InlineChoice",mediaInteraction:"taoQtiItem/qtiCreator/model/interactions/MediaInteraction",uploadInteraction:"taoQtiItem/qtiCreator/model/interactions/UploadInteraction",textEntryInteraction:"taoQtiItem/qtiCreator/model/interactions/TextEntryInteraction",sliderInteraction:"taoQtiItem/qtiCreator/model/interactions/SliderInteraction",extendedTextInteraction:"taoQtiItem/qtiCreator/model/interactions/ExtendedTextInteraction",hotspotInteraction:"taoQtiItem/qtiCreator/model/interactions/HotspotInteraction",selectPointInteraction:"taoQtiItem/qtiCreator/model/interactions/SelectPointInteraction",graphicInteraction:"taoQtiItem/qtiCreator/model/interactions/GraphicOrderInteraction",graphicAssociateInteraction:"taoQtiItem/qtiCreator/model/interactions/GraphicAssociateInteraction",graphicGapMatchInteraction:"taoQtiItem/qtiCreator/model/interactions/GraphicGapMatchInteraction",graphicOrderInteraction:"taoQtiItem/qtiCreator/model/interactions/GraphicOrderInteraction",hotspotChoice:"taoQtiItem/qtiCreator/model/choices/HotspotChoice",gapImg:"taoQtiItem/qtiCreator/model/choices/GapImg",associableHotspot:"taoQtiItem/qtiCreator/model/choices/AssociableHotspot",gapMatchInteraction:"taoQtiItem/qtiCreator/model/interactions/GapMatchInteraction",hottextInteraction:"taoQtiItem/qtiCreator/model/interactions/HottextInteraction",hottext:"taoQtiItem/qtiCreator/model/choices/Hottext",gapText:"taoQtiItem/qtiCreator/model/choices/GapText",gap:"taoQtiItem/qtiCreator/model/choices/Gap",responseDeclaration:"taoQtiItem/qtiCreator/model/variables/ResponseDeclaration",responseProcessing:"taoQtiItem/qtiCreator/model/ResponseProcessing",customInteraction:"taoQtiItem/qtiCreator/model/interactions/PortableCustomInteraction",endAttemptInteraction:"taoQtiItem/qtiCreator/model/interactions/EndAttemptInteraction",infoControl:"taoQtiItem/qtiCreator/model/PortableInfoControl",include:"taoQtiItem/qtiCreator/model/Include",printedVariable:"taoQtiItem/qtiCreator/model/PrintedVariable",_tooltip:"taoQtiItem/qtiCreator/model/Tooltip"},qtiClasses)}),define("taoQtiItem/qtiCreator/model/helper/container",["jquery","lodash","taoQtiItem/qtiCreator/model/qtiClasses"],function($,_,qtiClasses){"use strict";var methods={createElements:function(container,body,callback){var regex=/{{([a-z_]+)\.?([a-z_]*):new}}/ig,required={};body.replace(regex,function(original,qtiClass){if(qtiClasses[qtiClass])required[qtiClass]=qtiClasses[qtiClass];else throw new Error("missing required class : "+qtiClass)}),require(_.values(required),function(){var Qti=_.reduce([].slice.call(arguments),function(acc,qtiClassElt){return acc[qtiClassElt.prototype.qtiClass]=qtiClassElt,acc},{}),promises=[],$doc=$(document),newElts={},newBody=body.replace(regex,function(original,qtiClass,subClass){var elt=new Qti[qtiClass];return Qti[qtiClass]?(container.getRenderer()&&elt.setRenderer(container.getRenderer()),newElts[elt.getSerial()]=elt,subClass&&(elt.typeIdentifier=subClass),elt.placeholder()):original});container.setElements(newElts,newBody),_.each(newElts,function(elt){_.isFunction(elt.buildIdentifier)&&elt.buildIdentifier(),_.isFunction(elt.afterCreate)&&promises.push(elt.afterCreate())}),"function"==typeof callback&&Promise.all(promises).then(function(){_.each(newElts,function(elt){$doc.trigger("elementCreated.qti-widget",{parent:container.parent(),element:elt})}),callback.call(container,newElts)}).catch(function(err){container.getRenderer().getCreatorContext().trigger("error",err)})})}};return methods}),define("taoQtiItem/qtiCreator/model/mixin/editableContainer",["taoQtiItem/qtiCreator/model/helper/container"],function(containerHelper){"use strict";var methods={createElements:function(body,callback){var _this=this;containerHelper.createElements(_this.getBody(),body,function(newElts){callback.call(_this,newElts)})}};return methods}),define("taoQtiItem/qtiItem/core/IdentifiedElement",["taoQtiItem/qtiItem/core/Element","taoQtiItem/qtiItem/helper/util"],function(Element,util){"use strict";Element=Element&&Object.prototype.hasOwnProperty.call(Element,"default")?Element["default"]:Element,util=util&&Object.prototype.hasOwnProperty.call(util,"default")?util["default"]:util;var IdentifiedElement=Element.extend({buildIdentifier:function buildIdentifier(prefix,useSuffix){var item=this.getRootElement(),id=util.buildIdentifier(item,prefix||this.qtiClass,useSuffix);return id&&this.attr("identifier",id),this},id:function id(value){return value||this.attr("identifier")||this.buildIdentifier(this.qtiClass,!0),this.attr("identifier",value)}});return IdentifiedElement}),define("taoQtiItem/qtiItem/mixin/Mixin",[],function(){"use strict";var Mixin={augment:function(targetClass,methods,options){if("function"==typeof targetClass&&"object"==typeof methods)for(var methodName in methods)if(!Object.hasOwnProperty(targetClass.prototype,methodName))targetClass.prototype[methodName]=methods[methodName];else if(options&&options.append){var _parent=targetClass.prototype[methodName];targetClass.prototype[methodName]=function(){return methods[methodName].apply(this,arguments),_parent.apply(this,arguments)}}}};return Mixin}),define("taoQtiItem/qtiItem/core/Container",["jquery","lodash","taoQtiItem/qtiItem/core/Element","taoQtiItem/qtiItem/helper/rendererConfig"],function($,_,Element,rendererConfig){"use strict";$=$&&Object.prototype.hasOwnProperty.call($,"default")?$["default"]:$,_=_&&Object.prototype.hasOwnProperty.call(_,"default")?_["default"]:_,Element=Element&&Object.prototype.hasOwnProperty.call(Element,"default")?Element["default"]:Element,rendererConfig=rendererConfig&&Object.prototype.hasOwnProperty.call(rendererConfig,"default")?rendererConfig["default"]:rendererConfig;var Container=Element.extend({qtiClass:"_container",init:function(body){if(this._super(),body&&"string"!=typeof body)throw"the body of a container must be a string";this.bdy=body||"",this.elements={}},body:function(body){if("undefined"==typeof body)return this.bdy;if("string"==typeof body)this.bdy=body,$(document).trigger("containerBodyChange",{body:body,container:this,parent:this.parent()});else throw"body must be a string"},setElements:function(elements,body){var returnValue=!1;for(var i in elements){var elt=elements[i];if(elt instanceof Element)body=body||this.bdy,-1===body.indexOf(elt.placeholder())&&(body+=elt.placeholder()),elt.setRootElement(this.getRootElement()||null),this.elements[elt.getSerial()]=elt,$(document).trigger("containerElementAdded",{element:elt,container:this}),returnValue=!0;else throw returnValue=!1,"expected a qti element"}return this.body(body),returnValue},setElement:function(element,body){return this.setElements([element],body)},removeElement:function(element){var serial="";return"string"==typeof element?serial=element:element instanceof Element&&(serial=element.getSerial()),delete this.elements[serial],this.body(this.body().replace("{{"+serial+"}}","")),this},getElements:function(qtiClass){var elts={};if("string"==typeof qtiClass)for(var serial in this.elements)Element.isA(this.elements[serial],qtiClass)&&(elts[serial]=this.elements[serial]);else elts=_.clone(this.elements);return elts},getElement:function(serial){return this.elements[serial]?this.elements[serial]:null},getComposingElements:function(){var elements=this.getElements(),elts={};for(var serial in elements)elts[serial]=elements[serial],elts=_.extend(elts,elements[serial].getComposingElements());return elts},render:function(){var args=rendererConfig.getOptionsFromArguments(arguments),renderer=args.renderer||this.getRenderer(),elementsData=[],tpl=this.body();for(var serial in this.elements){var elt=this.elements[serial];if("function"==typeof elt.render)"_container"===elt.qtiClass?tpl=tpl.replace(elt.placeholder(),elt.render(renderer)):(tpl=tpl.replace(elt.placeholder(),"{{{"+serial+"}}}"),elementsData[serial]=elt.render(renderer));else throw"render() is not defined for the qti element: "+serial}if(renderer.isRenderer)return this._super({body:renderer.renderDirect(tpl,elementsData),contentModel:this.contentModel||"flow"},renderer,args.placeholder);throw"invalid qti renderer for qti container"},postRender:function(data,altClassName,renderer){renderer=renderer||this.getRenderer();var res=_(this.elements).filter(function(elt){return"function"==typeof elt.postRender}).map(function(elt){return elt.postRender(data,"",renderer)}).flatten(!0).value().concat(this._super(data,altClassName,renderer));return res},toArray:function(){var arr={serial:this.serial,body:this.bdy,elements:{}};for(var serial in this.elements)arr.elements[serial]=this.elements[serial].toArray();return arr},find:function(serial,parent){var found=null;return this.elements[serial]?found={parent:parent||this,element:this.elements[serial],location:"body"}:_.each(this.elements,function(elt){if(found=elt.find(serial),found)return!1}),found},isEmpty:function(){return!this.bdy}});return Container}),define("taoQtiItem/qtiItem/mixin/Container",["taoQtiItem/qtiItem/mixin/Mixin","taoQtiItem/qtiItem/core/Container"],function(Mixin,Container$1){"use strict";Mixin=Mixin&&Object.prototype.hasOwnProperty.call(Mixin,"default")?Mixin["default"]:Mixin,Container$1=Container$1&&Object.prototype.hasOwnProperty.call(Container$1,"default")?Container$1["default"]:Container$1;var methods={initContainer:function(body){this.bdy=new Container$1(body||""),this.bdy.setRootElement(this.getRootElement()||null),this.bdy.contentModel="blockStatic"},getBody:function(){return this.bdy},body:function(body){var ret=this.bdy.body(body);return body?this:ret},setElement:function(element,body){return this.bdy.setElement(element,body),this},removeElement:function(element){return this.bdy.removeElement(element)},getElements:function(qtiClass){return this.bdy.getElements(qtiClass)},getElement:function(serial){return this.bdy.getElement(serial)}},Container={augment:function(targetClass){Mixin.augment(targetClass,methods)},methods:methods};return Container}),define("taoQtiItem/qtiItem/mixin/ContainerItemBody",["taoQtiItem/qtiItem/mixin/Mixin","taoQtiItem/qtiItem/mixin/Container","lodash"],function(Mixin,Container,_){"use strict";Mixin=Mixin&&Object.prototype.hasOwnProperty.call(Mixin,"default")?Mixin["default"]:Mixin,Container=Container&&Object.prototype.hasOwnProperty.call(Container,"default")?Container["default"]:Container,_=_&&Object.prototype.hasOwnProperty.call(_,"default")?_["default"]:_;var methods={};_.extend(methods,Container.methods),_.extend(methods,{initContainer:function(body){Container.methods.initContainer.call(this,body),this.bdy.contentModel="itemBody"}});var ContainerItemBody={augment:function(targetClass){Mixin.augment(targetClass,methods)},methods:methods};return ContainerItemBody}),define("taoQtiItem/qtiItem/core/Item",["taoQtiItem/qtiItem/core/Element","taoQtiItem/qtiItem/core/IdentifiedElement","taoQtiItem/qtiItem/mixin/ContainerItemBody","lodash","jquery","taoQtiItem/qtiItem/helper/util"],function(Element,IdentifiedElement,Container,_,$,util){"use strict";Element=Element&&Object.prototype.hasOwnProperty.call(Element,"default")?Element["default"]:Element,IdentifiedElement=IdentifiedElement&&Object.prototype.hasOwnProperty.call(IdentifiedElement,"default")?IdentifiedElement["default"]:IdentifiedElement,Container=Container&&Object.prototype.hasOwnProperty.call(Container,"default")?Container["default"]:Container,_=_&&Object.prototype.hasOwnProperty.call(_,"default")?_["default"]:_,$=$&&Object.prototype.hasOwnProperty.call($,"default")?$["default"]:$,util=util&&Object.prototype.hasOwnProperty.call(util,"default")?util["default"]:util;var Item=IdentifiedElement.extend({qtiClass:"assessmentItem",init:function init(serial,attributes){this._super(serial,attributes),this.rootElement=this,this.stylesheets={},this.responses={},this.outcomes={},this.modalFeedbacks={},this.namespaces={},this.schemaLocations={},this.responseProcessing=null,this.apipAccessibility=null},getInteractions:function getInteractions(){var interactions=[],elts=this.getComposingElements();for(var serial in elts)Element.isA(elts[serial],"interaction")&&interactions.push(elts[serial]);return interactions},addResponseDeclaration:function addResponseDeclaration(response){if(Element.isA(response,"responseDeclaration"))response.setRootElement(this),this.responses[response.getSerial()]=response;else throw"is not a qti response declaration";return this},getResponseDeclaration:function getResponseDeclaration(identifier){for(var i in this.responses)if(this.responses[i].attr("identifier")===identifier)return this.responses[i];return null},addOutcomeDeclaration:function addOutcomeDeclaration(outcome){if(Element.isA(outcome,"outcomeDeclaration"))outcome.setRootElement(this),this.outcomes[outcome.getSerial()]=outcome;else throw"is not a qti outcome declaration";return this},getOutcomeDeclaration:function getOutcomeDeclaration(identifier){var found;return _.forEach(this.outcomes,function(outcome){if(outcome.id()===identifier)return found=outcome,!1}),found},getOutcomes:function getOutcomes(){return _.clone(this.outcomes)},removeOutcome:function removeOutcome(identifier){var outcome=this.getOutcomeDeclaration(identifier);outcome&&(this.outcomes=_.omit(this.outcomes,outcome.getSerial()))},addModalFeedback:function addModalFeedback(feedback){if(Element.isA(feedback,"modalFeedback"))feedback.setRootElement(this),this.modalFeedbacks[feedback.getSerial()]=feedback;else throw"is not a qti modal feedback";return this},getComposingElements:function getComposingElements(){var elts=this._super(),_this=this;return _.forEach(["responses","outcomes","modalFeedbacks","stylesheets"],function(elementCollection){for(var i in _this[elementCollection]){var elt=_this[elementCollection][i];elts[i]=elt,elts=_.extend(elts,elt.getComposingElements())}}),this.responseProcessing instanceof Element&&(elts[this.responseProcessing.getSerial()]=this.responseProcessing),elts},find:function find(serial){var found=this._super(serial);return found||(found=util.findInCollection(this,["responses","outcomes","modalFeedbacks","stylesheets"],serial)),found},getResponses:function getResponses(){return _.clone(this.responses)},getRootElement:function getRootElement(){return this},addNamespace:function addNamespace(name,uri){this.namespaces[name]=uri},setNamespaces:function setNamespaces(namespaces){this.namespaces=namespaces},getNamespaces:function getNamespaces(){return _.clone(this.namespaces)},setSchemaLocations:function setSchemaLocations(locations){this.schemaLocations=locations},getSchemaLocations:function getSchemaLocations(){return _.clone(this.schemaLocations)},setApipAccessibility:function setApipAccessibility(apip){this.apipAccessibility=apip||null},getApipAccessibility:function getApipAccessibility(){return this.apipAccessibility},addStylesheet:function addStylesheet(stylesheet){if(Element.isA(stylesheet,"stylesheet"))stylesheet.setRootElement(this),this.stylesheets[stylesheet.getSerial()]=stylesheet;else throw"is not a qti stylesheet declaration";return this},removeStyleSheet:function removeStyleSheet(stylesheet){return delete this.stylesheets[stylesheet.getSerial()],this},stylesheetExists:function stylesheetExists(href){var exists=!1;return _.forEach(this.stylesheets,function(stylesheet){if(stylesheet.attr("href")===href)return exists=!0,!1}),exists},setResponseProcessing:function setResponseProcessing(rp){if(Element.isA(rp,"responseProcessing"))rp.setRootElement(this),this.responseProcessing=rp;else throw"is not a response processing";return this},toArray:function toArray(){var arr=this._super(),toArray=function(elt){return elt.toArray()};return arr.namespaces=this.namespaces,arr.schemaLocations=this.schemaLocations,arr.outcomes=_.map(this.outcomes,toArray),arr.responses=_.map(this.responses,toArray),arr.stylesheets=_.map(this.stylesheets,toArray),arr.modalFeedbacks=_.map(this.modalFeedbacks,toArray),arr.responseProcessing=this.responseProcessing.toArray(),arr},isEmpty:function isEmpty(){var body=this.body().trim();if(body){var $dummy=$("
    ").html(body),$children=$dummy.children();return!!(1===$children.length&&$children.hasClass("empty"))}return!0},clear:function clear(){var renderer=this.getRenderer();renderer&&_.isFunction(renderer.destroy)&&renderer.destroy(this)}});return Container.augment(Item),Item}),define("taoQtiItem/qtiItem/core/Stylesheet",["taoQtiItem/qtiItem/core/Element","lodash","taoQtiItem/qtiItem/helper/rendererConfig"],function(Element,_,rendererConfig){"use strict";Element=Element&&Object.prototype.hasOwnProperty.call(Element,"default")?Element["default"]:Element,_=_&&Object.prototype.hasOwnProperty.call(_,"default")?_["default"]:_,rendererConfig=rendererConfig&&Object.prototype.hasOwnProperty.call(rendererConfig,"default")?rendererConfig["default"]:rendererConfig;var Stylesheet=Element.extend({qtiClass:"stylesheet",render:function(){var args=rendererConfig.getOptionsFromArguments(arguments),renderer=args.renderer||this.getRenderer(),defaultData={};return defaultData.attributes={href:renderer.resolveUrl(this.attr("href"))},this._super(_.merge(defaultData,args.data),args.placeholder,args.subclass,renderer)}});return Stylesheet}),define("taoQtiItem/qtiCreator/model/Stylesheet",["lodash","taoQtiItem/qtiCreator/model/mixin/editable","taoQtiItem/qtiItem/core/Stylesheet"],function(_,editable,Stylesheet){"use strict";var methods={};return _.extend(methods,editable),_.extend(methods,{getDefaultAttributes:function(){return{href:"css/tao-user-styles.css",title:"",type:"text/css",media:"all"}}}),Stylesheet.extend(methods)}),define("taoQtiItem/qtiItem/core/ResponseProcessing",["taoQtiItem/qtiItem/core/Element"],function(Element){"use strict";Element=Element&&Object.prototype.hasOwnProperty.call(Element,"default")?Element["default"]:Element;var ResponseProcessing=Element.extend({qtiClass:"responseProcessing",processingType:"",xml:"",toArray:function(){var arr=this._super();return arr.processingType=this.processingType,arr.xml=this.xml,arr}});return ResponseProcessing}),define("taoQtiItem/qtiItem/helper/interactionHelper",["lodash","taoQtiItem/qtiItem/core/Element"],function(_,Element){"use strict";var _Mathfloor=Math.floor;_=_&&Object.prototype.hasOwnProperty.call(_,"default")?_["default"]:_,Element=Element&&Object.prototype.hasOwnProperty.call(Element,"default")?Element["default"]:Element;var interactionHelper={convertChoices:function(choices,outputType){var ret=[],_this=this;return _.each(choices,function(c){Element.isA(c,"choice")?"serial"===outputType?ret.push(c.getSerial()):"identifier"===outputType?ret.push(c.id()):ret.push(c):_.isArray(c)&&ret.push(_this.convertChoices(c,outputType))}),ret},findChoices:function(interaction,choices,inputType){var ret=[],_this=this;return _.each(choices,function(c){var choice;_.isString(c)?"serial"===inputType?(choice=interaction.getChoice(c),choice&&ret.push(choice)):"identifier"===inputType?(choice=interaction.getChoiceByIdentifier(c),choice&&ret.push(choice)):ret.push(c):_.isArray(c)?ret.push(_this.findChoices(interaction,c,inputType)):ret.push(c)}),ret},shuffleChoices:function(choices){var r=[],f={},j=0;for(var i in choices)if(Element.isA(choices[i],"choice")){var choice=choices[i];choice.attr("fixed")&&(f[j]=choice),r.push(choice),j++}else throw"invalid element in array: is not a qti choice";for(var n=0;n!0).addList(required.map(module=>({module,category:"qti"}))).load().then(loaded=>{loaded.forEach(clazz=>{_isValidRenderer(clazz)&&(_renderers[clazz.qtiClass]=clazz)}),"function"==typeof callback&&callback.call(self,_renderers)}),this},this.unload=function unload(){return this.themeLoader&&themeLoader(options.themes).unload(),this},this.setShuffledChoices=function(interaction,choices,identificationType){Element.isA(interaction,"interaction")&&(this.shuffledChoices[interaction.getSerial()]=_.pluck(interactionHelper.findChoices(interaction,choices,identificationType),"serial"))},this.getShuffledChoices=function(interaction,reshuffle,returnedType){let choices=[],serial,i;if(Element.isA(interaction,"interaction")){if(serial=interaction.getSerial(),this.shuffledChoices[serial]&&!reshuffle)Element.isA(interaction,"matchInteraction")?_.forEach(choices,function(choice,index){2>index&&_.forEach(this.shuffledChoices[serial][i],function(choiceSerial){choice.push(interaction.getChoice(choiceSerial))})}):_.forEach(this.shuffledChoices[serial],function(choiceSerial){choices.push(interaction.getChoice(choiceSerial))});else if(Element.isA(interaction,"matchInteraction"))for(this.shuffledChoices[serial]=[],i=0;2>i;i++)choices[i]=interactionHelper.shuffleChoices(interaction.getChoices(i)),this.shuffledChoices[serial][i]=_.pluck(choices[i],"serial");else choices=interactionHelper.shuffleChoices(interaction.getChoices()),this.shuffledChoices[serial]=_.pluck(choices,"serial");return"serial"===returnedType||"identifier"===returnedType?interactionHelper.convertChoices(choices,returnedType):_.clone(choices)}return[]},this.getRenderers=function(){return _renderers},this.getLocations=function(){return _locations},this.resolveUrl=function resolveUrl(url){return options.assetManager?"string"==typeof url&&0maxChoice||responseDeclaration.correctResponse.lengthscore&&0>=requiredChoiceCount&&(score=0),requiredChoiceCount--,gamp.add(acc,score)},0),responseDeclaration.mappingAttributes.upperBound&&(max=_Mathmin(max,parseFloat(responseDeclaration.mappingAttributes.upperBound||0)))}else"MAP_RESPONSE_POINT"===template&&(max=0);return max},orderInteractionBased:function orderInteractionBased(interaction){var minChoice=0,maxChoice=parseInt(interaction.attr("maxChoices")||0,10),responseDeclaration=interaction.getResponseDeclaration(),template=responseHelper.getTemplateNameFromUri(responseDeclaration.template),max;return maxChoice&&0&&0>maxChoice?0:("MATCH_CORRECT"===template?_.isArray(responseDeclaration.correctResponse)&&maxChoice&&responseDeclaration.correctResponse.length>maxChoice||0?max=0:responseDeclaration.correctResponse&&(!_.isArray(responseDeclaration.correctResponse)||responseDeclaration.correctResponse.length)?max=1:max=0:("MAP_RESPONSE"===template||"MAP_RESPONSE_POINT"===template)&&(max=0),max)},associateInteractionBased:function associateInteractionBased(interaction,options){var responseDeclaration=interaction.getResponseDeclaration(),template=responseHelper.getTemplateNameFromUri(responseDeclaration.template),maxAssoc=parseInt(interaction.attr("maxAssociations")||0,10),minAssoc=0,mapDefault=parseFloat(responseDeclaration.mappingAttributes.defaultValue||0),max,requiredAssoc,totalAnswerableResponse,usedChoices,choicesIdentifiers,sortedMapEntries,i,allPossibleMapEntries,infiniteScoringPair;if(options=_.defaults(options||{},{possiblePairs:[],checkInfinitePair:!1}),maxAssoc&&minAssoc&&maxAssocmaxAssoc||minAssoc)?max=0:(max=1,choicesIdentifiers=[],_.forEach(responseDeclaration.correctResponse,function(pair){var choices;_.isString(pair)&&(choices=pair.trim().split(" "),_.isArray(choices)&&2===choices.length&&(choicesIdentifiers.push(choices[0].trim()),choicesIdentifiers.push(choices[1].trim())))}),_.forEach(_.countBy(choicesIdentifiers),function(count,identifier){var choice=interaction.getChoiceByIdentifier(identifier),matchMax;return choice?(matchMax=parseInt(choice.attr("matchMax"),10),matchMax&&matchMaxi;i++){if(choiceId=choices[i],!_usedChoices[choiceId]){if(choice=interaction.getChoiceByIdentifier(choiceId),!choice)return!1;_usedChoices[choiceId]={used:0,max:parseInt(choice.attr("matchMax"),10)}}if(_usedChoices[choiceId].max&&_usedChoices[choiceId].used===_usedChoices[choiceId].max)return!1;_usedChoices[choiceId].used++}return infiniteScoringPair=infiniteScoringPair||options.checkInfinitePair&&0v.score&&0>=requiredAssoc&&(score=0),requiredAssoc--,gamp.add(acc,score)},0),responseDeclaration.mappingAttributes.upperBound&&(max=_Mathmin(max,parseFloat(responseDeclaration.mappingAttributes.upperBound||0)))}else"MAP_RESPONSE_POINT"===template&&(max=0);return max},gapMatchInteractionBased:function gapMatchInteractionBased(interaction){var responseDeclaration=interaction.getResponseDeclaration(),template=responseHelper.getTemplateNameFromUri(responseDeclaration.template),mapDefault=parseFloat(responseDeclaration.mappingAttributes.defaultValue||0),getMatchMaxOrderedChoices=function getMatchMaxOrderedChoices(choiceCollection){return _(choiceCollection).map(function(choice){return{matchMax:0===choice.attr("matchMax")?1/0:choice.attr("matchMax")||0,id:choice.id()}}).sortBy("matchMax").reverse().valueOf()},calculatePossiblePairs=function calculatePossiblePairs(gapMatchInteraction){var pairs=[],matchSet1=getMatchMaxOrderedChoices(gapMatchInteraction.getChoices()),matchSet2=getMatchMaxOrderedChoices(gapMatchInteraction.getGaps());return _.forEach(matchSet1,function(choice1){_.forEach(matchSet2,function(choice2){pairs.push([choice1.id,choice2.id])})}),pairs},max,skippableWrongResponse,totalAnswerableResponse,usedChoices,usedGaps,group1,group2,allPossibleMapEntries;if("MATCH_CORRECT"===template)responseDeclaration.correctResponse&&(!_.isArray(responseDeclaration.correctResponse)||responseDeclaration.correctResponse.length)?(max=1,group1=[],group2=[],_.forEach(responseDeclaration.correctResponse,function(pair){var choices;_.isString(pair)&&(choices=pair.trim().split(" "),_.isArray(choices)&&2===choices.length&&(group1.push(choices[0].trim()),group2.push(choices[1].trim())))}),_.forEach(_.countBy(group1),function(count,identifier){var choice=interaction.getChoiceByIdentifier(identifier),matchMax=parseInt(choice.attr("matchMax"),10);if(matchMax&&matchMaxlanguages.reduce((memo,lang)=>(memo[lang.code]=lang.label,memo),{}),useCKEFormatting=languages=>languages.map(lang=>`${lang.code}:${lang.label}:${lang.orientation}`),getList=()=>null===languagesRequest?languagesRequest=request(languagesUrl,null,null,headers):languagesRequest,isRTLbyLanguageCode=code=>getList().then(languages=>{const lang=languages.filter(lang=>lang.code===code);return lang[0]&&"rtl"===lang[0].orientation||!1});return{useLegacyFormatting,useCKEFormatting,getList,isRTLbyLanguageCode}}),define("taoQtiItem/qtiCreator/helper/itemLoader",["jquery","lodash","taoQtiItem/qtiItem/core/Loader","taoQtiItem/qtiCreator/model/Item","taoQtiItem/qtiCreator/model/qtiClasses","taoQtiItem/qtiItem/helper/itemScore","core/dataProvider/request","taoQtiItem/qtiCreator/widgets/helpers/qtiIdentifier","taoQtiItem/qtiCreator/helper/languages"],function($,_,Loader,Item,qtiClasses,itemScoreHelper,request,qtiIdentifier,languages){"use strict";const _generateIdentifier=function _generateIdentifier(uri){const pos=uri.lastIndexOf("#");return uri.substring(pos+1,pos+1+qtiIdentifier.maxQtiIdLength)},decodeHtml=function(str){const map={"&":"&","<":"<",">":">",""":"\"","'":"'"};return str.replace(/&|<|>|"|'/g,function(m){return map[m]})},qtiNamespace="http://www.imsglobal.org/xsd/imsqti_v2p2",qtiSchemaLocation={"http://www.imsglobal.org/xsd/imsqti_v2p2":"http://www.imsglobal.org/xsd/qti/qtiv2p2/imsqti_v2p2.xsd"},creatorLoader={loadItem:function loadItem(config,callback){if(config.uri){const langList=languages.getList(),itemRdf=request(config.itemDataUrl,{uri:config.uri}).catch(d=>d);Promise.all([langList,itemRdf]).then(_ref3=>{let[languagesList,data]=_ref3;if(data.itemData)for(const response in data.itemData.responses){const newObject={};for(const mapKey in data.itemData.responses[response].mapping)newObject[decodeHtml(mapKey)]=data.itemData.responses[response].mapping[mapKey];data.itemData.responses[response].mapping=newObject}if(data.itemData&&"assessmentItem"===data.itemData.qtiClass){const loader=new Loader().setClassesLocation(qtiClasses),itemData=data.itemData;loader.loadItemData(itemData,function(loadedItem){loadedItem.isEmpty()&&loadedItem.body("");const namespaces=loadedItem.getNamespaces();namespaces[""]=qtiNamespace,loadedItem.setNamespaces(namespaces),loadedItem.setSchemaLocations(qtiSchemaLocation),languagesList&&loadedItem.data("languagesList",languagesList);const{responseProcessing:{processingType}={}}=loadedItem;if(!config.perInteractionRp&&"templateDriven"===processingType){const{responses={},responseProcessing:{data,responseRules=[]}={}}=itemData,responseIdentifiers=[];_.forOwn(responses,_ref4=>{let{identifier}=_ref4;responseIdentifiers.push(identifier)});const itemScoreRP=itemScoreHelper(responseIdentifiers);responseRules.some(responseRule=>_.isEqual(responseRule,itemScoreRP))&&loadedItem.responseProcessing.setProcessingType("custom",data)}callback(loadedItem,this.getLoadedClasses())})}else{const newItem=new Item().id(_generateIdentifier(config.uri)).attr("title",config.label);newItem.createResponseProcessing(),newItem.setNamespaces({"":qtiNamespace,xsi:"http://www.w3.org/2001/XMLSchema-instance",m:"http://www.w3.org/1998/Math/MathML"}),newItem.setSchemaLocations(qtiSchemaLocation),newItem.data("new",!0),languagesList&&newItem.data("languagesList",languagesList),callback(newItem)}})}}};return creatorLoader}),define("taoQtiItem/portableElementRegistry/assetManager/portableAssetStrategy",["taoQtiItem/portableElementRegistry/ciRegistry","taoQtiItem/portableElementRegistry/icRegistry"],function(ciRegistry,icRegistry){"use strict";function getBaseUrlByIdentifier(typeIdentifier){return ciRegistry.get(typeIdentifier)?ciRegistry.getBaseUrl(typeIdentifier):icRegistry.get(typeIdentifier)?icRegistry.getBaseUrl(typeIdentifier):typeIdentifier}return{name:"portableElementLocation",handle:function handlePortableElementLocation(url){if(url.file===url.path)return getBaseUrlByIdentifier(url.file);return url.source===url.relative?url.relative.replace(/^(\.\/)?([a-z_0-9]+)\/(.*)/i,function(fullmatch,$1,typeIdentifier,relPath){var runtimeLocation=getBaseUrlByIdentifier(typeIdentifier);return runtimeLocation?runtimeLocation+"/"+relPath:fullmatch}):void 0}}}),define("taoQtiItem/qtiCommonRenderer/renderers/config",["lodash","context","ui/themes","taoItems/assets/manager","taoItems/assets/strategies","module","taoQtiItem/portableElementRegistry/assetManager/portableAssetStrategy"],function(_,context,themes,assetManagerFactory,assetStrategies,module,portableAssetStrategy){"use strict";_=_&&Object.prototype.hasOwnProperty.call(_,"default")?_["default"]:_,context=context&&Object.prototype.hasOwnProperty.call(context,"default")?context["default"]:context,themes=themes&&Object.prototype.hasOwnProperty.call(themes,"default")?themes["default"]:themes,assetManagerFactory=assetManagerFactory&&Object.prototype.hasOwnProperty.call(assetManagerFactory,"default")?assetManagerFactory["default"]:assetManagerFactory,assetStrategies=assetStrategies&&Object.prototype.hasOwnProperty.call(assetStrategies,"default")?assetStrategies["default"]:assetStrategies,module=module&&Object.prototype.hasOwnProperty.call(module,"default")?module["default"]:module,portableAssetStrategy=portableAssetStrategy&&Object.prototype.hasOwnProperty.call(portableAssetStrategy,"default")?portableAssetStrategy["default"]:portableAssetStrategy;var itemThemes=themes.get("items"),moduleConfig=module.config(),assetManager=assetManagerFactory([{name:"theme",handle:function handleTheme(url){if(itemThemes&&url.path&&(url.path===itemThemes.base||_.contains(_.pluck(itemThemes.available,"path"),url.path)))return context.root_url+url.toString()}},assetStrategies.taomedia,assetStrategies.external,assetStrategies.base64,assetStrategies.itemCssNoCache,assetStrategies.baseUrl,portableAssetStrategy],{baseUrl:""}),locations={assessmentItem:"taoQtiItem/qtiCommonRenderer/renderers/Item",_container:"taoQtiItem/qtiCommonRenderer/renderers/Container",_simpleFeedbackRule:!1,_tooltip:"taoQtiItem/qtiCommonRenderer/renderers/Tooltip",stylesheet:"taoQtiItem/qtiCommonRenderer/renderers/Stylesheet",outcomeDeclaration:!1,responseDeclaration:!1,responseProcessing:!1,figure:"taoQtiItem/qtiCommonRenderer/renderers/Figure",img:"taoQtiItem/qtiCommonRenderer/renderers/Img",figcaption:"taoQtiItem/qtiCommonRenderer/renderers/Figcaption",math:"taoQtiItem/qtiCommonRenderer/renderers/Math",object:"taoQtiItem/qtiCommonRenderer/renderers/Object",table:"taoQtiItem/qtiCommonRenderer/renderers/Table",printedVariable:"taoQtiItem/qtiCommonRenderer/renderers/PrintedVariable",rubricBlock:"taoQtiItem/qtiCommonRenderer/renderers/RubricBlock",modalFeedback:"taoQtiItem/qtiCommonRenderer/renderers/ModalFeedback",prompt:"taoQtiItem/qtiCommonRenderer/renderers/interactions/Prompt",choiceInteraction:"taoQtiItem/qtiCommonRenderer/renderers/interactions/ChoiceInteraction",extendedTextInteraction:"taoQtiItem/qtiCommonRenderer/renderers/interactions/ExtendedTextInteraction",orderInteraction:"taoQtiItem/qtiCommonRenderer/renderers/interactions/OrderInteraction",associateInteraction:"taoQtiItem/qtiCommonRenderer/renderers/interactions/AssociateInteraction",matchInteraction:"taoQtiItem/qtiCommonRenderer/renderers/interactions/MatchInteraction",textEntryInteraction:"taoQtiItem/qtiCommonRenderer/renderers/interactions/TextEntryInteraction",sliderInteraction:"taoQtiItem/qtiCommonRenderer/renderers/interactions/SliderInteraction",inlineChoiceInteraction:"taoQtiItem/qtiCommonRenderer/renderers/interactions/InlineChoiceInteraction","simpleChoice.choiceInteraction":"taoQtiItem/qtiCommonRenderer/renderers/choices/SimpleChoice.ChoiceInteraction","simpleChoice.orderInteraction":"taoQtiItem/qtiCommonRenderer/renderers/choices/SimpleChoice.OrderInteraction",hottext:"taoQtiItem/qtiCommonRenderer/renderers/choices/Hottext",gap:"taoQtiItem/qtiCommonRenderer/renderers/choices/Gap",gapText:"taoQtiItem/qtiCommonRenderer/renderers/choices/GapText","simpleAssociableChoice.matchInteraction":"taoQtiItem/qtiCommonRenderer/renderers/choices/SimpleAssociableChoice.MatchInteraction","simpleAssociableChoice.associateInteraction":"taoQtiItem/qtiCommonRenderer/renderers/choices/SimpleAssociableChoice.AssociateInteraction",inlineChoice:"taoQtiItem/qtiCommonRenderer/renderers/choices/InlineChoice",hottextInteraction:"taoQtiItem/qtiCommonRenderer/renderers/interactions/HottextInteraction",hotspotInteraction:"taoQtiItem/qtiCommonRenderer/renderers/interactions/HotspotInteraction",hotspotChoice:!1,gapMatchInteraction:"taoQtiItem/qtiCommonRenderer/renderers/interactions/GapMatchInteraction",selectPointInteraction:"taoQtiItem/qtiCommonRenderer/renderers/interactions/SelectPointInteraction",graphicOrderInteraction:"taoQtiItem/qtiCommonRenderer/renderers/interactions/GraphicOrderInteraction",mediaInteraction:"taoQtiItem/qtiCommonRenderer/renderers/interactions/MediaInteraction",uploadInteraction:"taoQtiItem/qtiCommonRenderer/renderers/interactions/UploadInteraction",graphicGapMatchInteraction:"taoQtiItem/qtiCommonRenderer/renderers/interactions/GraphicGapMatchInteraction",gapImg:"taoQtiItem/qtiCommonRenderer/renderers/choices/GapImg",graphicAssociateInteraction:"taoQtiItem/qtiCommonRenderer/renderers/interactions/GraphicAssociateInteraction",associableHotspot:!1,customInteraction:"taoQtiItem/qtiCommonRenderer/renderers/interactions/PortableCustomInteraction",infoControl:"taoQtiItem/qtiCommonRenderer/renderers/PortableInfoControl",include:"taoQtiItem/qtiCommonRenderer/renderers/Include",endAttemptInteraction:"taoQtiItem/qtiCommonRenderer/renderers/interactions/EndAttemptInteraction"},config={name:"commonRenderer",locations:locations,options:{assetManager:assetManager,themes:itemThemes,enableDragAndDrop:{associate:!!moduleConfig.associateDragAndDrop,gapMatch:!!moduleConfig.gapMatchDragAndDrop,graphicGapMatch:!!moduleConfig.graphicGapMatchDragAndDrop,order:!!moduleConfig.orderDragAndDrop},messages:moduleConfig.messages}};return config}),define("taoQtiItem/qtiCreator/renderers/config",["lodash","context","taoQtiItem/qtiCommonRenderer/renderers/config","taoItems/assets/manager","taoItems/assets/strategies"],function(_,context,commonRenderConfig,assetManagerFactory,assetStrategies){"use strict";var assetManager=assetManagerFactory([assetStrategies.taomedia,assetStrategies.external,assetStrategies.base64,assetStrategies.baseUrl],{baseUrl:""}),locations=_.defaults({_container:"taoQtiItem/qtiCreator/renderers/Container",_tooltip:"taoQtiItem/qtiCreator/renderers/Tooltip",assessmentItem:"taoQtiItem/qtiCreator/renderers/Item",rubricBlock:"taoQtiItem/qtiCreator/renderers/RubricBlock",figure:"taoQtiItem/qtiCreator/renderers/Figure",img:"taoQtiItem/qtiCreator/renderers/Img",figcaption:"taoQtiItem/qtiCreator/renderers/Figcaption",math:"taoQtiItem/qtiCreator/renderers/Math",object:"taoQtiItem/qtiCreator/renderers/Object",table:"taoQtiItem/qtiCreator/renderers/Table",modalFeedback:"taoQtiItem/qtiCreator/renderers/ModalFeedback",choiceInteraction:"taoQtiItem/qtiCreator/renderers/interactions/ChoiceInteraction",orderInteraction:"taoQtiItem/qtiCreator/renderers/interactions/OrderInteraction",matchInteraction:"taoQtiItem/qtiCreator/renderers/interactions/MatchInteraction",associateInteraction:"taoQtiItem/qtiCreator/renderers/interactions/AssociateInteraction",inlineChoiceInteraction:"taoQtiItem/qtiCreator/renderers/interactions/InlineChoiceInteraction",textEntryInteraction:"taoQtiItem/qtiCreator/renderers/interactions/TextEntryInteraction",hotspotInteraction:"taoQtiItem/qtiCreator/renderers/interactions/HotspotInteraction",selectPointInteraction:"taoQtiItem/qtiCreator/renderers/interactions/SelectPointInteraction",graphicOrderInteraction:"taoQtiItem/qtiCreator/renderers/interactions/GraphicOrderInteraction",graphicAssociateInteraction:"taoQtiItem/qtiCreator/renderers/interactions/GraphicAssociateInteraction",graphicGapMatchInteraction:"taoQtiItem/qtiCreator/renderers/interactions/GraphicGapMatchInteraction",mediaInteraction:"taoQtiItem/qtiCreator/renderers/interactions/MediaInteraction",uploadInteraction:"taoQtiItem/qtiCreator/renderers/interactions/UploadInteraction",sliderInteraction:"taoQtiItem/qtiCreator/renderers/interactions/SliderInteraction",extendedTextInteraction:"taoQtiItem/qtiCreator/renderers/interactions/ExtendedTextInteraction",inlineChoice:"taoQtiItem/qtiCreator/renderers/choices/InlineChoice","simpleChoice.choiceInteraction":"taoQtiItem/qtiCreator/renderers/choices/SimpleChoice.ChoiceInteraction","simpleChoice.orderInteraction":"taoQtiItem/qtiCreator/renderers/choices/SimpleChoice.OrderInteraction","simpleAssociableChoice.associateInteraction":"taoQtiItem/qtiCreator/renderers/choices/SimpleAssociableChoice.AssociateInteraction","simpleAssociableChoice.matchInteraction":"taoQtiItem/qtiCreator/renderers/choices/SimpleAssociableChoice.MatchInteraction",gapMatchInteraction:"taoQtiItem/qtiCreator/renderers/interactions/GapMatchInteraction",hottextInteraction:"taoQtiItem/qtiCreator/renderers/interactions/HottextInteraction",customInteraction:"taoQtiItem/qtiCreator/renderers/interactions/PortableCustomInteraction",endAttemptInteraction:"taoQtiItem/qtiCreator/renderers/interactions/EndAttemptInteraction",infoControl:"taoQtiItem/qtiCreator/renderers/PortableInfoControl",include:"taoQtiItem/qtiCreator/renderers/Include",gap:"taoQtiItem/qtiCreator/renderers/choices/Gap",gapText:"taoQtiItem/qtiCreator/renderers/choices/GapText",hottext:"taoQtiItem/qtiCreator/renderers/choices/Hottext",printedVariable:"taoQtiItem/qtiCreator/renderers/PrintedVariable"},commonRenderConfig.locations);return{name:"creatorRenderer",locations:locations,options:{assetManager:assetManager}}}),define("taoQtiItem/qtiCreator/renderers/Renderer",["taoQtiItem/qtiRunner/core/Renderer","taoQtiItem/qtiCreator/renderers/config"],function(Renderer,config){"use strict";return Renderer.build(config.locations,config.name,config.options)}),define("taoQtiItem/qtiCreator/helper/creatorRenderer",["jquery","lodash","taoQtiItem/qtiCreator/renderers/Renderer","taoItems/assets/manager","taoItems/assets/strategies","util/dom"],function($,_,Renderer,assetManagerFactory,assetStrategies,dom){"use strict";var _creatorRenderer=null,_configurableInteractions=["endAttempt"],_extractInteractionsConfig=function _extractInteractionsConfig(config){var ret={};return config&&config.properties&&_.each(_configurableInteractions,function(interactionName){config.properties[interactionName]&&(ret[interactionName]=config.properties[interactionName])}),ret},get=function(reset,config,areaBroker){var $bodyEltForm;return config=config||{},config.properties=config.properties||{},(!_creatorRenderer||reset)&&($bodyEltForm=_creatorRenderer?_creatorRenderer.getOption("bodyElementOptionForm"):null,(reset||!$bodyEltForm||!$bodyEltForm.length||!dom.contains($bodyEltForm))&&(_creatorRenderer=new Renderer({lang:"",uri:"",shuffleChoices:!1,itemOptionForm:$("#item-editor-item-property-bar .panel"),interactionOptionForm:$("#item-editor-interaction-property-bar .panel"),choiceOptionForm:$("#item-editor-choice-property-bar .panel"),responseOptionForm:$("#item-editor-response-property-bar .panel"),bodyElementOptionForm:areaBroker.getElementPropertyPanelArea(),textOptionForm:$("#item-editor-text-property-bar .panel"),modalFeedbackOptionForm:$("#item-editor-modal-feedback-property-bar .panel"),mediaManager:{appendContainer:"#mediaManager",browseUrl:config.properties.getFilesUrl,uploadUrl:config.properties.fileUploadUrl,deleteUrl:config.properties.fileDeleteUrl,downloadUrl:config.properties.fileDownloadUrl,fileExistsUrl:config.properties.fileExistsUrl,mediaSourcesUrl:config.properties.mediaSourcesUrl},interactions:_extractInteractionsConfig(config),qtiCreatorContext:config.qtiCreatorContext}),_creatorRenderer.getAssetManager().setData({baseUrl:config.properties.baseUrl||""}),_creatorRenderer.setAreaBroker(areaBroker),_.assign(_creatorRenderer,{getCreatorContext:function getCreatorContext(){return this.getOption("qtiCreatorContext")}}))),_creatorRenderer};return{get:get,setOption:function(name,value){return get().setOption(name,value)},setOptions:function(options){return get().setOptions(options)},load:function(qtiClasses,done){return get().load(function(){_.isFunction(done)&&done.apply(this,arguments)},qtiClasses)}}}),define("taoQtiItem/qtiCommonRenderer/renderers/Renderer",["taoQtiItem/qtiRunner/core/Renderer","taoQtiItem/qtiCommonRenderer/renderers/config"],function(Renderer$1,config){"use strict";Renderer$1=Renderer$1&&Object.prototype.hasOwnProperty.call(Renderer$1,"default")?Renderer$1["default"]:Renderer$1,config=config&&Object.prototype.hasOwnProperty.call(config,"default")?config["default"]:config;var Renderer=Renderer$1.build(config.locations,config.name,config.options);return Renderer}),define("taoQtiItem/qtiCommonRenderer/helpers/container",["lodash","jquery","taoQtiItem/qtiItem/core/Element"],function(_,$,Element){"use strict";_=_&&Object.prototype.hasOwnProperty.call(_,"default")?_["default"]:_,$=$&&Object.prototype.hasOwnProperty.call($,"default")?$["default"]:$,Element=Element&&Object.prototype.hasOwnProperty.call(Element,"default")?Element["default"]:Element;let _containers={},_$containerContext=$();const _getSelector=function(element){const serial=element.getSerial();let selector=`[data-serial=${serial}]`;return Element.isA(element,"choice")?selector=`.qti-choice${selector}`:Element.isA(element,"interaction")&&(selector=`.qti-interaction${selector}`),selector},containerHelper={setContext($scope){_$containerContext=$scope},getContext(){return _$containerContext},get(element,$scope){const serial=element.getSerial();return $scope instanceof $&&$scope.length?$scope.find(_getSelector(element)):_$containerContext instanceof $&&_$containerContext.length?_$containerContext.find(_getSelector(element)):(_containers[serial]&&_containers[serial].length||(_containers[serial]=$(_getSelector(element))),_containers[serial])},reset(element){element instanceof Element&&_containers[element.getSerial()]&&(_containers=_.omit(_containers,element.getSerial()))},clear(){_containers={},_$containerContext=$()},trigger(eventType,element,data){eventType&&(data&&!_.isArray(data)&&(data=[data]),this.get(element).trigger(eventType,data))},triggerResponseChangeEvent(interaction,extraData){this.trigger("responseChange",interaction,[{interaction:interaction,response:interaction.getResponse()},extraData])},targetBlank($container){$container.on("click","a",function(e){e.preventDefault();const href=$(this).attr("href");href&&href.match(/^http/i)&&window.open(href,"_blank")})}};return containerHelper}),define("taoQtiItem/qtiCreator/helper/commonRenderer",["lodash","taoQtiItem/qtiCommonRenderer/renderers/Renderer","taoQtiItem/qtiCommonRenderer/helpers/container"],function(_,Renderer,containerHelper){"use strict";var _$previousContext=null,commonRenderer={render:function(item,$container){return commonRenderer.setContext($container),_renderer.load(function(){$container.append(item.render(this)),item.postRender({},"",this)},item.getUsedClasses())},get:function(reset,config){return(!_renderer||reset)&&(_renderer=new Renderer({shuffleChoices:!0}),config&&_renderer.getAssetManager().setData({baseUrl:config.properties.baseUrl||""})),_renderer},getOption:function(name){return _renderer.getOption(name)},setOption:function(name,value){return _renderer.setOption(name,value)},setOptions:function(options){return _renderer.setOptions(options)},setContext:function($context){return _$previousContext=$context,containerHelper.setContext($context)},restoreContext:function(){containerHelper.setContext(_$previousContext),_$previousContext=null},load:function(qtiClasses,done){var renderer=_renderer||this.get();return renderer.load(function(){_.isFunction(done)&&done.apply(this,arguments)},qtiClasses)}},_renderer;return commonRenderer}),define("taoQtiItem/qtiItem/helper/simpleParser",["lodash","jquery","taoQtiItem/qtiItem/helper/util","taoQtiItem/qtiItem/core/Loader"],function(_,$,util,Loader){"use strict";function _getElementSelector(qtiClass,ns){return ns?ns+"\\:"+qtiClass+","+qtiClass:qtiClass}function getQtiClassFromXmlDom($node){let qtiClass=$node.prop("tagName").toLowerCase();return qtiClass=qtiClass.replace(/.*:/,""),_qtiClassNames[qtiClass]?_qtiClassNames[qtiClass]:qtiClass}function buildElement($elt){const qtiClass=getQtiClassFromXmlDom($elt),elt={qtiClass:qtiClass,serial:util.buildSerial(qtiClass+"_"),attributes:{}};return $.each($elt[0].attributes,function(){let attrName;this.specified&&(attrName=_qtiAttributesNames[this.name]||this.name,elt.attributes[attrName]=this.value)}),elt}function buildMath($elt,options){const elt=buildElement($elt);return elt.annotations={},$elt.find(_getElementSelector("annotation",options.ns.math)).each(function(){const $annotation=$(this),encoding=$annotation.attr("encoding");encoding&&(elt.annotations[encoding]=_.unescape($annotation.html())),$annotation.remove()}),elt.mathML=$elt.html(),elt.ns={name:"m",uri:"http://www.w3.org/1998/Math/MathML"},elt}function buildTooltip(targetHtml,contentId,contentHtml){const qtiClass="_tooltip";return{elements:{},qtiClass:"_tooltip",serial:util.buildSerial("_tooltip_"),attributes:{"aria-describedby":contentId},content:contentHtml,body:{elements:{},serial:util.buildSerial("container"),body:targetHtml}}}function parseTable($elt,elt,options){elt.body={body:"",elements:{}};const $parsedTable=parseContainer($elt,options);return elt.body.body=$parsedTable.body,elt.body.elements=$parsedTable.elements,elt}function parseFigure($elt,elt,options){elt.body={body:"",elements:{}};const $parsedFigure=parseContainer($elt,options);elt.body.body=$parsedFigure.body,elt.body.elements=$parsedFigure.elements;const $figcaption=$elt.find(_getElementSelector("figcaption",options.ns.figcaption));if($figcaption.length){const element=buildElement($figcaption);element.body={body:$figcaption.html(),elements:{}},elt.body.elements[element.serial]=element,$figcaption.replaceWith(_placeholder(element))}return elt.body.body=$elt.html(),elt}function parseContainer($container,options){const ret={serial:util.buildSerial("_container_"),body:"",elements:{}};return $container.find("table").each(function(){const $qtiElement=$(this);let element=buildElement($qtiElement);element=parseTable($qtiElement,element,options),ret.elements[element.serial]=element,$qtiElement.replaceWith(_placeholder(element))}),$container.find(_getElementSelector("figure",options.ns.figure)).each(function(){const $qtiElement=$(this);let element=buildElement($qtiElement);element=parseFigure($qtiElement,element,options),ret.elements[element.serial]=element,$qtiElement.replaceWith(_placeholder(element))}),$container.find(_getElementSelector("math",options.ns.math)).each(function(){const $qtiElement=$(this),element=buildMath($qtiElement,options);ret.elements[element.serial]=element,$qtiElement.replaceWith(_placeholder(element))}),$container.find(_getElementSelector("include",options.ns.include)).each(function(){const $qtiElement=$(this),element=buildElement($qtiElement);ret.elements[element.serial]=element,$qtiElement.replaceWith(_placeholder(element))}),$container.find("[data-role=\"tooltip-target\"]").each(function(){let $target=$(this),contentId=$target.attr("aria-describedBy"),element,$content,contentHtml;contentId&&($content=$container.find("#"+contentId),$content.length&&(contentHtml=$content.html(),element=buildTooltip($target.html(),contentId,contentHtml),ret.elements[element.serial]=element,$target.replaceWith(_placeholder(element)),$content.remove()))}),_.each(_parsableElements,function(qtiClass){$container.find(qtiClass).each(function(){const $qtiElement=$(this),element=buildElement($qtiElement);ret.elements[element.serial]=element,$qtiElement.replaceWith(_placeholder(element))})}),ret.body=$container.html(),ret}function _placeholder(element){return"{{"+element.serial+"}}"}_=_&&Object.prototype.hasOwnProperty.call(_,"default")?_["default"]:_,$=$&&Object.prototype.hasOwnProperty.call($,"default")?$["default"]:$,util=util&&Object.prototype.hasOwnProperty.call(util,"default")?util["default"]:util,Loader=Loader&&Object.prototype.hasOwnProperty.call(Loader,"default")?Loader["default"]:Loader;const _parsableElements=["img","object","printedVariable"],_qtiClassNames={rubricblock:"rubricBlock",printedvariable:"printedVariable"},_qtiAttributesNames={powerform:"powerForm",mappingindicator:"mappingIndicator"},_defaultOptions={ns:{math:"",include:"xi",table:"table",image:"img",object:"",figure:"qh5",figcaption:"qh5"},loaded:null,model:null};let parser;parser={parse:function(xmlStr,opts){const options=_.merge(_.clone(_defaultOptions),opts||{}),$container=$(xmlStr),element=buildElement($container),data=parseContainer($container,options);let loader;return _.isUndefined(data.body)||(element.body=data),_.isFunction(options.loaded)&&options.model&&(loader=new Loader().setClassesLocation(options.model),loader.loadAndBuildElement(element,options.loaded)),element}};var parser$1=parser;return parser$1}),define("taoQtiItem/qtiItem/helper/xincludeLoader",["jquery","lodash","taoQtiItem/qtiItem/helper/simpleParser","taoQtiItem/qtiItem/core/Loader"],function($,_,simpleParser,Loader){"use strict";function load(xinclude,baseUrl,callback){const href=xinclude.attr("href");if(href&&baseUrl){const fileUrl=`text!${baseUrl}${href}`;require.undef(fileUrl),require([fileUrl],function(stimulusXml){const $wrapper=$.parseXML(stimulusXml),$sampleXMLrootNode=$wrapper.children,$stimulus=$("").append($sampleXMLrootNode),mathNs="m",data=simpleParser.parse($stimulus,{ns:{math:mathNs}});new Loader().loadElement(xinclude,data,function(){if(_.isFunction(callback)){const loadedClasses=this.getLoadedClasses();loadedClasses.push("_container"),callback(xinclude,data,loadedClasses)}})},function(){callback(xinclude,!1,[])})}}$=$&&Object.prototype.hasOwnProperty.call($,"default")?$["default"]:$,_=_&&Object.prototype.hasOwnProperty.call(_,"default")?_["default"]:_,simpleParser=simpleParser&&Object.prototype.hasOwnProperty.call(simpleParser,"default")?simpleParser["default"]:simpleParser,Loader=Loader&&Object.prototype.hasOwnProperty.call(Loader,"default")?Loader["default"]:Loader;var xincludeLoader={load};return xincludeLoader}),define("taoQtiItem/qtiCreator/helper/xincludeRenderer",["module","context","lodash","taoQtiItem/qtiCreator/helper/commonRenderer","taoQtiItem/qtiItem/helper/xincludeLoader","core/moduleLoader"],function(module,context,_,commonRenderer,xincludeLoader,moduleLoader){"use strict";const moduleConfig=module.config();let xincludeHandlers=[];return moduleConfig.handlers&&moduleLoader({},_.isFunction).addList(moduleConfig.handlers).load(context.bundle).then(handlers=>xincludeHandlers=handlers),{render:function render(xincludeWidget,baseUrl,newHref){const xinclude=xincludeWidget.element;newHref&&xinclude.attr("href",newHref),xincludeLoader.load(xinclude,baseUrl,function(xi,data,loadedClasses){if(data){const dataBody=data.body.body,hasClass=dataBody.match(/class="(?tao-\w+)?/);let className="";hasClass&&hasClass.groups&&hasClass.groups.className&&(className=hasClass.groups.className),commonRenderer.get().load(function(){_.each(xinclude.getComposingElements(),function(elt){elt.setRenderer(commonRenderer.get())}),xincludeWidget.refresh()},loadedClasses),xincludeHandlers.forEach(handler=>handler(xinclude.attr("href"),className,xi.serial))}else xinclude.removeAttr("href")})},getXincludeHandlers:function getXincludeHandlers(){return xincludeHandlers}}}),define("tpl!taoQtiItem/qtiCreator/tpl/toolbars/insertInteractionButton",["handlebars"],function(hb){return hb.template(function(Handlebars,depth0,helpers,partials,data){function program1(depth0,data){var buffer="",stack1,helper;return buffer+="\n data-sub-group=\"",(helper=helpers.subGroup)?stack1=helper.call(depth0,{hash:{},data:data}):(helper=depth0&&depth0.subGroup,stack1="function"===typeof helper?helper.call(depth0,{hash:{},data:data}):helper),buffer+=escapeExpression(stack1)+"\"\n",buffer}function program3(depth0,data){return"\n class=\"disabled\"\n title=\"element available in the final release\"\n"}function program5(depth0,data){var buffer="",stack1,helper;return buffer+="\n title=\"",(helper=helpers.title)?stack1=helper.call(depth0,{hash:{},data:data}):(helper=depth0&&depth0.title,stack1="function"===typeof helper?helper.call(depth0,{hash:{},data:data}):helper),buffer+=escapeExpression(stack1)+"\"\n",buffer}function program7(depth0,data){var buffer="",stack1,helper;return buffer+="\n \n ",buffer}function program9(depth0,data){var buffer="",stack1,helper;return buffer+="\n \n ",buffer}this.compilerInfo=[4,">= 1.0.0"],helpers=this.merge(helpers,Handlebars.helpers),data=data||{};var buffer="",functionType="function",escapeExpression=this.escapeExpression,self=this,stack1,helper;return buffer+="\n ",stack1=helpers["if"].call(depth0,depth0&&depth0.iconFont,{hash:{},inverse:self.program(9,program9,data),fn:self.program(7,program7,data),data:data}),(stack1||0===stack1)&&(buffer+=stack1),buffer+="\n\n
    ",(helper=helpers.short)?stack1=helper.call(depth0,{hash:{},data:data}):(helper=depth0&&depth0.short,stack1="function"===typeof helper?helper.call(depth0,{hash:{},data:data}):helper),buffer+=escapeExpression(stack1)+"
    \n",buffer})}),define("tpl!taoQtiItem/qtiCreator/tpl/toolbars/insertInteractionGroup",["handlebars"],function(hb){return hb.template(function(Handlebars,depth0,helpers,partials,data){this.compilerInfo=[4,">= 1.0.0"],helpers=this.merge(helpers,Handlebars.helpers),data=data||{};var buffer="",functionType="function",escapeExpression=this.escapeExpression,stack1,helper;return buffer+="
    \n

    ",(helper=helpers.label)?stack1=helper.call(depth0,{hash:{},data:data}):(helper=depth0&&depth0.label,stack1="function"===typeof helper?helper.call(depth0,{hash:{},data:data}):helper),buffer+=escapeExpression(stack1)+"

    \n
    \n
      \n
      \n
      ",buffer})}),define("tpl!taoQtiItem/qtiCreator/tpl/toolbars/tooltip",["handlebars"],function(hb){return hb.template(function(Handlebars,depth0,helpers,partials,data){this.compilerInfo=[4,">= 1.0.0"],helpers=this.merge(helpers,Handlebars.helpers),data=data||{};var buffer="",functionType="function",escapeExpression=this.escapeExpression,stack1,helper;return buffer+="
      \n \n
      \n ",(helper=helpers.message)?stack1=helper.call(depth0,{hash:{},data:data}):(helper=depth0&&depth0.message,stack1="function"===typeof helper?helper.call(depth0,{hash:{},data:data}):helper),buffer+=escapeExpression(stack1)+"\n
      \n
      ",buffer})}),define("taoQtiItem/qtiCreator/editor/interactionsToolbar",["jquery","lodash","i18n","ui/hider","tpl!taoQtiItem/qtiCreator/tpl/toolbars/insertInteractionButton","tpl!taoQtiItem/qtiCreator/tpl/toolbars/insertInteractionGroup","tpl!taoQtiItem/qtiCreator/tpl/toolbars/tooltip","ui/tooltip"],function($,_,__,hider,insertInteractionTpl,insertSectionTpl,tooltipTpl,tooltip){"use strict";function getGroupId(groupId){return groupId.replace(/\W+/g,"-").toLowerCase()}function getGroupSectionId(groupId){return"sidebar-left-section-"+getGroupId(groupId)}function addGroup($sidebar,groupId,groupLabel){const groupSectionId=getGroupSectionId(groupId),$section=$(insertSectionTpl({id:groupSectionId,label:groupLabel}));return $sidebar.append($section),$section}function create($sidebar,interactions){_.each(interactions,function(interactionAuthoringData){add($sidebar,interactionAuthoringData)}),buildSubGroups($sidebar),$sidebar.data("interaction-toolbar-ready",!0),$sidebar.trigger(_events.interactiontoolbarready)}function getGroup($sidebar,groupId){const groupSectionId=getGroupSectionId(groupId);return $sidebar.find("#"+groupSectionId)}function isReady($sidebar){return!!$sidebar.data("interaction-toolbar-ready")}function whenReady($sidebar){return new Promise(function(resolve){isReady($sidebar)?resolve():$sidebar.on(_events.interactiontoolbarready,function(){resolve()})})}function remove($sidebar,interactionClass){$sidebar.find("li[data-qti-class=\""+interactionClass+"\"]").remove()}function disable($sidebar,interactionClass){hider.hide($sidebar.find("li[data-qti-class=\""+interactionClass+"\"]"))}function enable($sidebar,interactionClass){hider.show($sidebar.find("li[data-qti-class=\""+interactionClass+"\"]"))}function exists($sidebar,interactionClass){return!!$sidebar.find("li[data-qti-class=\""+interactionClass+"\"]").length}function add($sidebar,interactionAuthoringData){if(exists($sidebar,interactionAuthoringData.qtiClass))throw"the interaction is already in the sidebar";const groupId=interactionAuthoringData.group,groupLabel=interactionAuthoringData.tags[0]||"",subGroupId=interactionAuthoringData.tags[1],tplData={qtiClass:interactionAuthoringData.qtiClass,disabled:!!interactionAuthoringData.disabled,title:interactionAuthoringData.description,iconFont:/^icon-/.test(interactionAuthoringData.icon),icon:interactionAuthoringData.icon,short:interactionAuthoringData.short,dev:!1};let $group=getGroup($sidebar,groupId);subGroupId&&_subgroups[subGroupId]&&(tplData.subGroup=subGroupId),$group.length||($group=addGroup($sidebar,groupId,groupLabel)),subGroupId&&_subgroups[subGroupId]&&(tplData.subGroup=subGroupId),$group.length||($group=addGroup($sidebar,groupId,groupLabel));let $interaction=$(insertInteractionTpl(tplData));return $group.find(".tool-list").append($interaction),$interaction}function buildSubGroups($sidebar){$sidebar.find("[data-sub-group]").each(function(){var $element=$(this),$section=$element.parents("section"),subGroup=$element.data("sub-group"),$subGroupPanel,$subGroupList,$cover;subGroup&&($subGroupPanel=$section.find(".sub-group."+subGroup),$subGroupList=$subGroupPanel.find(".tool-list"),!$subGroupPanel.length&&($subGroupPanel=$("
      ",{class:"panel clearfix sub-group "+subGroup}),$subGroupList=$("
        ",{class:"tool-list plain clearfix"}),$subGroupPanel.append($subGroupList),$section.append($subGroupPanel),$cover=$("
        ",{class:"sub-group-cover blocking"}),$subGroupPanel.append($cover),$subGroupPanel.data("cover",$cover)),$subGroupList.append($element))}),addInlineInteractionTooltip()}function addInlineInteractionTooltip(){var $inlineInteractionsPanel=$("#sidebar-left-section-inline-interactions .inline-interactions"),$tooltip=$(tooltipTpl({message:__("Inline interactions need to be inserted into a text block.")})),timer;$inlineInteractionsPanel.append($tooltip),tooltip.lookup($inlineInteractionsPanel),$tooltip.css({position:"absolute",zIndex:11,top:0,right:10}),$inlineInteractionsPanel.on("mouseenter",".sub-group-cover",function(){timer=setTimeout(function(){$tooltip.find("[data-tooltip]").data("$tooltip").show()},300)}).on("mouseleave",".sub-group-cover",function(){$tooltip.find("[data-tooltip]").data("$tooltip").hide(),clearTimeout(timer)})}var _customInteractionTag=__("Custom Interactions"),_subgroups={"inline-interactions":"Inline Interactions"},_events={interactiontoolbarready:"interactiontoolbarready.qti-widget"};return{create:create,add:add,exists:exists,addGroup:addGroup,getGroupId:getGroupId,getGroupSectionId:getGroupSectionId,getGroup:getGroup,isReady:isReady,whenReady:whenReady,remove:remove,disable:disable,enable:enable,getCustomInteractionTag:function(){return _customInteractionTag}}}),define("taoQtiItem/qtiCreator/helper/panel",["jquery","lodash","i18n","taoQtiItem/qtiItem/core/Element"],function($,_,__,Element){"use strict";var _getItemContainer=function(){return $("#item-editor-panel")},showPanel=function($panel,$fold){$panel.show(),openSections($panel.children("section")),$fold&&$fold.length&&closeSections($fold.children("section"))},initFormVisibilityListener=function(){$(document).off(".panel");var $itemContainer=_getItemContainer(),_staticElements={_tooltip:"Tooltip",figure:"Figure",img:"Image",object:"Media",rubricBlock:"Rubric Block",math:"Math",table:"Table",include:"Shared Stimulus",infoControl:"Student Tool"},$formInteractionPanel=$("#item-editor-interaction-property-bar"),$formChoicePanel=$("#item-editor-choice-property-bar"),$formResponsePanel=$("#item-editor-response-property-bar"),$formItemPanel=$("#item-editor-item-property-bar"),$formBodyElementPanel=$("#item-editor-body-element-property-bar"),$formTextBlockPanel=$("#item-editor-text-property-bar"),$formModalFeedbackPanel=$("#item-editor-modal-feedback-property-bar"),$formStylePanel=$("#item-style-editor-bar"),$appearanceToggler=$("#appearance-trigger"),$menuLabel=$appearanceToggler.find(".menu-label"),$itemIcon=$appearanceToggler.find(".icon-item"),$styleIcon=$appearanceToggler.find(".icon-style"),_toggleAppearanceEditor=function(active){active?($appearanceToggler.addClass("active"),$formStylePanel.show(),$formItemPanel.hide(),$itemContainer.trigger("styleedit"),showPanel($formStylePanel),$menuLabel.text($menuLabel.data("item")),$itemIcon.show(),$styleIcon.hide()):($appearanceToggler.removeClass("active"),$formStylePanel.hide(),showPanel($formItemPanel),$menuLabel.text($menuLabel.data("style")),$itemIcon.hide(),$styleIcon.show())};$appearanceToggler.on("click",function(){$appearanceToggler.hasClass("active")?_toggleAppearanceEditor(!1):_toggleAppearanceEditor(!0)}),_.delay(function(){showPanel($formItemPanel)},200),$(document).on("afterStateInit.qti-widget.panel",function(e,element,state){switch(state.name){case"active":_toggleAppearanceEditor(!1),Element.isA(element,"assessmentItem")||$formItemPanel.hide();var label=_staticElements[element.qtiClass];label?($formBodyElementPanel.find("h2").html(label+" "+__("Properties")),showPanel($formBodyElementPanel)):"_container"===element.qtiClass&&showPanel($formTextBlockPanel),"modalFeedback"===element.qtiClass&&(showPanel($formModalFeedbackPanel),$formResponsePanel.hide());break;case"question":showPanel($formInteractionPanel);break;case"answer":showPanel($formResponsePanel);break;case"choice":showPanel($formChoicePanel,$formInteractionPanel);break;case"sleep":_staticElements[element.qtiClass]?$formBodyElementPanel.hide():"_container"===element.qtiClass&&$formTextBlockPanel.hide(),Element.isA(element,"choice")||$itemContainer.find(".widget-box.edit-active").length||showPanel($formItemPanel)}}).on("afterStateExit.qti-widget.panel",function(e,element,state){switch(state.name){case"active":"modalFeedback"===element.qtiClass&&(showPanel($formResponsePanel),$formModalFeedbackPanel.hide());break;case"question":element.is("interaction")&&($formChoicePanel.hide(),$formInteractionPanel.hide());break;case"choice":$formChoicePanel.hide(),showPanel($formInteractionPanel);break;case"answer":$formResponsePanel.hide()}}).on("elementCreated.qti-widget.panel",function(e,data){"_container"===data.element.qtiClass&&enableSubGroup("inline-interactions")}).on("deleted.qti-widget.panel",function(e,data){"_container"===data.element.qtiClass&&toggleInlineInteractionGroup()})},toggleInlineInteractionGroup=function(){var $itemContainer=_getItemContainer();$itemContainer.find(".widget-textBlock").length?enableSubGroup("inline-interactions"):disableSubGroup("inline-interactions")},heading="h2",section="section",panel="hr, .panel",closed="closed",ns="accordion",initSidebarAccordion=function($sidebar){var $sections=$sidebar.find(section),$allPanels=$sidebar.children(panel).hide(),$allTriggers=$sidebar.find(heading);return!(0!==$allTriggers.length)||void($allTriggers.each(function(){var $heading=$(this),$section=$heading.parents(section),$panel=$section.children(panel),$closer=$("",{class:"icon-up"}),$opener=$("",{class:"icon-down"}),action=$panel.is(":visible")?"open":"close";($heading.append($closer).append($opener).addClass(closed),!$heading.hasClass("_accordion"))&&($heading.addClass("_accordion"),$panel.on("panelclose."+ns+" panelopen."+ns,function(e,args){var fn="panelclose"===e.type?"add":"remove";args.heading[fn+"Class"](closed)}),$panel.trigger("panel"+action+"."+ns,{heading:$heading}))}),$sections.each(function(){$(this).find(heading).on("click",function(e,args){var $heading=$(this),$panel=$heading.parents(section).children(panel),preserveOthers=!!(args&&args.preserveOthers),actions={close:"hide",open:"fadeIn"},forceState=!!(args&&args.forceState)&&args.forceState,action,classFn;forceState&&(classFn="open"===forceState?"addClass":"removeClass",$heading[classFn](closed)),action=$heading.hasClass(closed)?"open":"close",!1,$panel.trigger("panel"+action+"."+ns,{heading:$heading})[actions[action]]()})}))},_toggleSections=function(sections,preserveOthers,state){sections.each(function(){$(this).find(heading).trigger("click",{preserveOthers:preserveOthers,forceState:state})})},closeSections=function(sections,preserveOthers){_toggleSections(sections,!!preserveOthers,"close")},openSections=function(sections,preserveOthers){_toggleSections(sections,!!preserveOthers,"open")},_toggleSubGroup=function(subGroup,state){if(subGroup=$("."+subGroup),subGroup.length){var fn="disable"===state?"addClass":"removeClass";subGroup.data("cover")[fn]("blocking")}},enableSubGroup=function(subGroup){_toggleSubGroup(subGroup,"enable")},disableSubGroup=function(subGroup){_toggleSubGroup(subGroup,"disable")};return{initFormVisibilityListener:initFormVisibilityListener,showPanel:showPanel,toggleInlineInteractionGroup:toggleInlineInteractionGroup,initSidebarAccordion:initSidebarAccordion,openSections:openSections,closeSections:closeSections,enableSubGroup:enableSubGroup,disableSubGroup:disableSubGroup}}),define("taoQtiItem/qtiCreator/editor/interactionsPanel",["taoQtiItem/qtiCreator/editor/interactionsToolbar","taoQtiItem/qtiCreator/helper/panel","taoQtiItem/qtiCreator/helper/qtiElements","taoQtiItem/portableElementRegistry/ciRegistry"],function(interactionsToolbar,panel,qtiElements,ciRegistry){"use strict";return function setUpInteractionPanel($container){const interactions=qtiElements.getAvailableAuthoringElements();for(const typeId in ciRegistry.getAllVersions()){const data=ciRegistry.getAuthoringData(typeId,{enabledOnly:!0});data&&data.tags&&data.tags[0]===interactionsToolbar.getCustomInteractionTag()&&(interactions[data.qtiClass]=data)}interactionsToolbar.create($container,interactions),panel.initSidebarAccordion($container),panel.closeSections($container.find("section")),panel.openSections($container.find("#sidebar-left-section-common-interactions"),!1),panel.toggleInlineInteractionGroup()}}),define("tpl!taoQtiItem/qtiCreator/tpl/toolbars/cssToggler",["handlebars"],function(hb){return hb.template(function(Handlebars,depth0,helpers,partials,data){this.compilerInfo=[4,">= 1.0.0"],helpers=this.merge(helpers,Handlebars.helpers),data=data||{};var buffer="",functionType="function",escapeExpression=this.escapeExpression,stack1,helper;return buffer+="
      • \n \n ",(helper=helpers.label)?stack1=helper.call(depth0,{hash:{},data:data}):(helper=depth0&&depth0.label,stack1="function"===typeof helper?helper.call(depth0,{hash:{},data:data}):helper),buffer+=escapeExpression(stack1)+"\n \n \n \n
      • ",buffer})}),define("taoQtiItem/qtiCreator/editor/styleEditor/styleEditor",["jquery","lodash","i18n","util/urlParser","core/promise","tpl!taoQtiItem/qtiCreator/tpl/toolbars/cssToggler","jquery.fileDownload"],function($,_,__,UrlParser,Promise,cssTpl){"use strict";let itemConfig,globalConfig;const _getUri=function(action){return globalConfig[`${action}CssUrl`]},_basename=function(path){return path.substring(path.lastIndexOf("/")+1)};let style={};const $styleElem=function(){let styleElem=$("#item-editor-user-styles");return styleElem.length?styleElem.empty():(styleElem=$("