'use strict';

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

var _react = require('react');

var _react2 = _interopRequireDefault(_react);

var _propTypes = require('prop-types');

var _propTypes2 = _interopRequireDefault(_propTypes);

var _reactTabs = require('react-tabs');

require('react-tabs/style/react-tabs.css');

var _Editor = require('../Editor/Editor');

var _Editor2 = _interopRequireDefault(_Editor);

var _InstructionsEditor = require('../InstructionsEditor/InstructionsEditor');

var _InstructionsEditor2 = _interopRequireDefault(_InstructionsEditor);

var _TestSpecEditor = require('../TestSpecEditor/TestSpecEditor');

var _TestSpecEditor2 = _interopRequireDefault(_TestSpecEditor);

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

var EditModeTabs = function EditModeTabs(_ref) {
  var initialCode = _ref.initialCode,
      showLints = _ref.showLints,
      instructions = _ref.instructions,
      testSpec = _ref.testSpec,
      handleInstructionsChange = _ref.handleInstructionsChange,
      handleTestSpecChange = _ref.handleTestSpecChange,
      handleBoilerplateChange = _ref.handleBoilerplateChange;
  return _react2.default.createElement(
    _reactTabs.Tabs,
    null,
    _react2.default.createElement(
      _reactTabs.TabList,
      null,
      _react2.default.createElement(
        _reactTabs.Tab,
        null,
        'Boilerplate'
      ),
      _react2.default.createElement(
        _reactTabs.Tab,
        null,
        'Instructions'
      ),
      _react2.default.createElement(
        _reactTabs.Tab,
        null,
        'Tests'
      )
    ),
    _react2.default.createElement(
      _reactTabs.TabPanel,
      null,
      _react2.default.createElement(_Editor2.default, {
        code: initialCode,
        showLints: showLints,
        onAnyCode: handleBoilerplateChange
      })
    ),
    _react2.default.createElement(
      _reactTabs.TabPanel,
      null,
      _react2.default.createElement(_InstructionsEditor2.default, { code: instructions, onAnyCode: handleInstructionsChange })
    ),
    _react2.default.createElement(
      _reactTabs.TabPanel,
      null,
      _react2.default.createElement(_TestSpecEditor2.default, { code: testSpec, onAnyCode: handleTestSpecChange })
    )
  );
};

exports.default = EditModeTabs;