Documentation

Gap Binder

Description

Addon works with the text and table module. Reads the contents of the gap from the text (and table) module it works with and verifies them. In check errors mode, assign the appropriate classes to the gaps in the text and table modules. In show answers mode, inserts the declared values into the gaps from the text and table module.

Requirements

If the requirements are not fulfilled, the gap binder addon may not work properly with other modules.

Setting properties of co-working modules

In order for the addon to work properly it is required to: * for co-working Table addons check the "Is not an activity" property. * for co-working Text modules uncheck the "Is activity" property.

Setting the order co-working modules

In the editor, set the order of the gap binder addon so that it is in front of the co-working modules.

Properties

Property name Description
Modules' IDs (Text or Table) IDs of Text or Table modules it works with. Each identifier is separated by comma.
Answers Entered consecutive values that are correct answers (each line is one answer).

Supported commands

Command name Params Description
isOK moduleIndex, gapIndex Returns true if gap is filled in correctly, otherwise false.
isAllOK --- Returns true if all gaps are filled in correctly and there are no mistakes, otherwise false.
isAttempted --- Returns true if any of the gaps have been filled, otherwise false.

Events

The module does not block or modify the events sent by the modules specified in the configuration. If a change is made in the co-working module, the event of the co-working module and the event of the gap binder will be sent. The event of the co-working module sends information according to its own unchanged configuration.

Value Changed event

Event name Params Description
ValueChanged
  • Source - module ID (gap binder)
  • Item - gap number (according to the order defined in the gap binder)
  • Value - gap content
  • Source - "1" if correct, "0" if incorrect
Sent by interaction when a user changes state (enters new text, etc.)

All OK event

Event name Params Description
ValueChanged
  • Source - module ID (gap binder)
  • Item - "all"
  • Value - empty string ("")
  • Source - empty string ("")
Sent by interaction when a user changes state and the score of the module is 100%

CSS Classes

Class name Description
.gap_binder_invalid Addon's invalid configuration