"use strict";

var _interopRequireDefault = require("@babel/runtime-corejs3/helpers/interopRequireDefault");

var _Object$defineProperty = require("@babel/runtime-corejs3/core-js-stable/object/define-property");

_Object$defineProperty(exports, "__esModule", {
  value: true
});

exports.default = void 0;

var _extends2 = _interopRequireDefault(require("@babel/runtime-corejs3/helpers/extends"));

var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime-corejs3/helpers/objectWithoutProperties"));

var _react = _interopRequireDefault(require("react"));

var _pickers = require("@material-ui/pickers");

var DateField = function DateField(_ref) {
  var value = _ref.value,
      _onChange = _ref.onChange,
      otherProps = (0, _objectWithoutProperties2.default)(_ref, ["value", "onChange"]);
  return /*#__PURE__*/_react.default.createElement(_pickers.DateTimePicker, (0, _extends2.default)({
    fullWidth: true,
    variant: "inline",
    inputVariant: "outlined",
    margin: "normal",
    value: value,
    onChange: function onChange(date) {
      return date === undefined ? _onChange() : _onChange(date.toISOString());
    }
  }, otherProps));
};

var _default = DateField;
exports.default = _default;
//# sourceMappingURL=DateTimeField.js.map