gradereport_grader/collapse

Description:
  • Allow the user to show and hide columns of the report at will.

Source:
License:
  • http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later

Allow the user to show and hide columns of the report at will.

Methods

clickHandler(e)

Description:
  • The handler for when a user interacts with the component.

Source:
Parameters:
Name Type Description
e MouseEvent

The triggering event that we are working with.

componentSelector() → {string}

Description:
  • The overall div that contains the searching widget.

Source:
Returns:
Type
string

countUpdate()

Description:
  • Update the visual count of collapsed columns or hide the count all together.

Source:

(async) docClickHandler(e) → {Promise.<void>}

Description:
  • Externally defined click function to improve memory handling.

Source:
Parameters:
Name Type Description
e MouseEvent
Returns:
Type
Promise.<void>
Description:
  • The dropdown div that contains the searching widget result space.

Source:
Returns:
Type
string

fetchCustomFieldValues() → {array.<string, *>}

Description:
  • If we have any custom user profile fields, grab their system & readable names to add to our string map.

Source:
Returns:

An array of associated string arrays ready for our map.

Type
array.<string, *>

fetchDataset() → {string}

Description:
  • Get the data we will be searching against in this component.

Source:
Returns:
Type
string

fetchRequiredGradeStrings() → {Promise.<void>}

Description:
  • Given the set of gradable items we can possibly search, fetch their strings, so we can report to screen readers the field that matched.

Source:
Returns:
Type
Promise.<void>

fetchRequiredUserStrings() → {Promise.<void>}

Description:
  • Given the set of profile fields we can possibly search, fetch their strings, so we can report to screen readers the field that matched.

Source:
Returns:
Type
Promise.<void>

(async) filterDataset(filterableData) → {Array}

Description:
  • Dictate to the search component how and what we want to match upon.

Source:
Parameters:
Name Type Description
filterableData Array
Returns:

An array of objects containing the system reference and the user readable value.

Type
Array

filterMatchDataset()

Description:
  • Given we have a subset of the dataset, set the field that we matched upon to inform the end user.

Source:

getDataset() → {Array}

Description:
  • Return the dataset that we will be searching upon.

Source:
Returns:
Type
Array

(async) keyHandler(e)

Description:
  • The handler for when a user presses a key within the component.

Source:
Parameters:
Name Type Description
e KeyboardEvent

The triggering event that we are working with.

(async) prefcountpipe() → {Promise.<void>}

Description:
  • Update the user preferences, count display then render the results.

Source:
Returns:
Type
Promise.<void>

registerClickHandlers()

Description:
  • Register clickable event listeners.

Source:

registerFormEvents()

Description:
  • Handle the form submission within the dropdown.

Source:

registerInputEvents()

Description:
  • Handle any keyboard inputs.

Source:

(async) renderDefault()

Description:
  • Build the content then replace the node by default we want our form to exist.

Source:

(async) renderDropdown()

Description:
  • Build the content then replace the node.

Source:

setPreferences()

Description:
  • Given a user performs an action, update the users' preferences.

Source:

triggerSelector() → {string}

Description:
  • The triggering div that contains the searching widget.

Source:
Returns:
Type
string

updateDisplay()

Description:
  • With an array of nodes, switch their classes and values.

Source: