Documentation

Gap Binder

Description

The Gap Binder module 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 module may not work properly with other modules.

Setting properties of co-working modules

For the module to work properly it is required to:

  • for co-working Table modules check the "Is not an activity" property.
  • for co-working Text modules uncheck the "Is activity" property.

Setting the order of the co-working modules

In the editor, set the order of the Gap Binder module so that it is in front of the co-working modules.

Properties

The list starts with the common properties, learn more about them by visiting the Modules description section. The other available properties are described below.

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