config.annotations - Initialization - Items API

Items API Initialization

annotations

Enables the use of Annotations API in the assessment and is loaded with all default modules.

You would want to specify this option so that you can offer learners the ability to make notes, add multi color highlights to text, place sticky notes onto the page, and use a pen tool to annotate the Item content.

Examples

// Enable the use of Annotations API
var initializationOptions = {
    "annotations": true
    // ...
};

// For use with "inline" assessments, specify the DOM element '#assessment-wrapper' when initializing Items API
// e.g. <div id="assessment-wrapper"></div>
const itemsApp = LearnosityItems.init(initOptions, '#assessment-wrapper', eventsOptions);

Values

Attribute path config.annotations

Type boolean

Caveats

When using with rendering_type set to "inline", you must provide a container element with a specific ID to indicate which area of the page can be used to insert annotations. If no container element is provided, the body element will be used by default, which may lead to unintended placements of the annotations on the page. The provided container element should also use either position: relative, or position: absolute; CSS styling.

Related articles

Was this article helpful?

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