config.navigation.warning_on_change - Initialization - Items API

Items API Initialization

warning_on_change

Shows a warning message when the learner navigates to another Item but has not fully attempted the Question(s) in the current Item.

You would want to specify this option so that you can warn learners that they may lose points if they don't complete all responses in the current Item.

The warning message will appear if the current Item has any unattempted Questions or does not satisfy the minimum requirements for the Question.

Examples

// Enable the warning dialog
var initializationOptions = {
    "config": {
        "navigation": {
            "warning_on_change": true
        }
    }
};

// Enable the warning dialog and prevent the learner from progressing until all Questions are attempted
var initializationOptions = {
    "config": {
        "navigation": {
            "warning_on_change": {
                "disable_item_navigation": true
            }
        }
    }
};

Values

Attribute path config.navigation.warning_on_change

Default false

  • Type boolean

    Setting this value to true will show a warning dialog to the learner. The learner can choose to ignore the message and continue to navigate to another Item.

  • Type object

    • disable_item_navigation boolean

      Setting this value to true will hide the continue button on the warning dialog, preventing the learner from navigating to another Item until they have attempted all the Questions.

      Default: false

Was this article helpful?

Did you arrive here by accident? If so, learn more about Learnosity.