'use strict';

Object.defineProperty(exports, "__esModule", {
  value: true
});

var _reactRedux = require('../../../../../react-redux');

var _stateHelper = require('../../../../../util/stateHelper');

var _stateHelper2 = _interopRequireDefault(_stateHelper);

var _modifications = require('../../../../../actions/modifications');

var _ui = require('../../../../../actions/ui');

var _alerts = require('../../../../../actions/alerts');

var _presenter = require('./presenter');

var _presenter2 = _interopRequireDefault(_presenter);

function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }

var mapStateToProps = function mapStateToProps(state, props) {
  return {
    editingQuizEntry: _stateHelper2.default.editingQuizEntry(),
    interactionTypes: _stateHelper2.default.interactionTypes(),
    quizEntryWithErrorsShowing: _stateHelper2.default.quizEntryWithErrorsShowing()
  };
};

var mapDispatchToProps = {
  createItem: _modifications.createItem,
  createStimulus: _modifications.createStimulus,
  screenreaderNotification: _alerts.screenreaderNotification,
  setNextQuizEntry: _modifications.setNextQuizEntry,
  setUi: _ui.set
};

exports.default = (0, _reactRedux.connect)(mapStateToProps, mapDispatchToProps)(_presenter2.default);