"use strict";

Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.setFilter = exports.toggle = exports.update = exports.reset = void 0;

var _constants = require("@instructure/quiz-common/lib/constants");

var reset = function reset() {
  return {
    type: _constants.SEARCH_RESET
  };
};

exports.reset = reset;

var update = function update(text) {
  return {
    payload: {
      text: text
    },
    type: _constants.SEARCH_UPDATE
  };
};

exports.update = update;

var toggle = function toggle(filter, key) {
  return {
    payload: {
      filter: filter,
      key: key
    },
    type: _constants.SEARCH_TOGGLE
  };
};

exports.toggle = toggle;

var setFilter = function setFilter(filter, value) {
  return {
    payload: {
      filter: filter,
      value: value
    },
    type: _constants.SEARCH_SET
  };
};

exports.setFilter = setFilter;