"use strict";var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;exports.__esModule = true;exports.ViewDateInputValidateChecks = void 0;var _inheritsLoose2 = _interopRequireDefault(require("@babel/runtime/helpers/inheritsLoose"));var _react = _interopRequireDefault(require("react"));

var _constants = require("../../lib/date/constants");
var _InternalDate = require("../../lib/date/InternalDate");
var _types = require("../../lib/date/types");
var _Checkbox = require("../Checkbox");
var _Gapped = require("../Gapped");var







ViewDateInputValidateChecks = exports.ViewDateInputValidateChecks = /*#__PURE__*/function (_React$Component) {function ViewDateInputValidateChecks() {return _React$Component.apply(this, arguments) || this;}(0, _inheritsLoose2.default)(ViewDateInputValidateChecks, _React$Component);var _proto = ViewDateInputValidateChecks.prototype;_proto.
  render = function render() {
    var internalDate = new _InternalDate.InternalDate();
    internalDate.parseInternalValue(this.props.value);
    internalDate.setRangeStart(this.props.minDate ? new _InternalDate.InternalDate().parseInternalValue(this.props.minDate) : null);
    internalDate.setRangeEnd(this.props.maxDate ? new _InternalDate.InternalDate().parseInternalValue(this.props.maxDate) : null);

    return /*#__PURE__*/(
      _react.default.createElement(_Gapped.Gapped, { gap: 10, vertical: true }, /*#__PURE__*/
      _react.default.createElement("h3", null, "\u0412\u043D\u0443\u0442\u0440\u0435\u043D\u043D\u0438\u0435 \u043F\u0440\u043E\u0432\u0435\u0440\u043A\u0438"), /*#__PURE__*/
      _react.default.createElement(_Checkbox.Checkbox, { disabled: true, checked: internalDate.validate({ checks: [_types.InternalDateValidateCheck.NotNull] }) }, "\u2B63 ", /*#__PURE__*/
      _react.default.createElement("code", { style: { color: 'black' } }, "NotNull"), /*#__PURE__*/
      _react.default.createElement("div", null, "\u0412\u0441\u0435 \u043A\u043E\u043C\u043F\u043E\u043D\u0435\u043D\u0442\u044B \u0434\u0430\u0442\u044B \u0437\u0430\u043F\u043E\u043B\u043D\u0435\u043D\u044B (\u043D\u0435 \u0440\u0430\u0432\u043D\u044B",
      ' ', /*#__PURE__*/
      _react.default.createElement("b", null, /*#__PURE__*/
      _react.default.createElement("code", null, "null")
      ), ")"

      )
      ), /*#__PURE__*/
      _react.default.createElement(_Checkbox.Checkbox, { disabled: true, checked: internalDate.validate({ checks: [_types.InternalDateValidateCheck.Limits] }) }, "\u2B63 ", /*#__PURE__*/
      _react.default.createElement("code", { style: { color: 'black' } }, "Limits"), /*#__PURE__*/
      _react.default.createElement("div", null, "\u041A\u043E\u043C\u043F\u043E\u043D\u0435\u043D\u0442\u044B \u0434\u0430\u0442\u044B \u043D\u0435 \u0432\u044B\u0445\u043E\u0434\u044F\u0442 \u0437\u0430 \u0440\u0430\u043C\u043A\u0438 \u043F\u0440\u0435\u0434\u0443\u0441\u0442\u0430\u043D\u043E\u0432\u043B\u0435\u043D\u043D\u044B\u0445 \u043B\u0438\u043C\u0438\u0442\u043E\u0432", /*#__PURE__*/

      _react.default.createElement("br", null), "\u0413\u043E\u0434: ",
      _constants.MIN_YEAR, " - ", _constants.MAX_YEAR, /*#__PURE__*/
      _react.default.createElement("br", null), "\u041C\u0435\u0441\u044F\u0446: ",
      _constants.MIN_MONTH, " - ", _constants.MAX_MONTH, /*#__PURE__*/
      _react.default.createElement("br", null), "\u0427\u0438\u0441\u043B\u043E: ",
      _constants.MIN_DATE, " - ", _constants.MAX_DATE
      )
      ), /*#__PURE__*/
      _react.default.createElement(_Checkbox.Checkbox, { disabled: true, checked: internalDate.validate({ checks: [_types.InternalDateValidateCheck.Native] }) }, "\u2B63 ", /*#__PURE__*/
      _react.default.createElement("code", { style: { color: 'black' } }, "Native"), /*#__PURE__*/
      _react.default.createElement("div", null, "\u0418\u0437 \u043A\u043E\u043C\u043F\u043E\u043D\u0435\u043D\u0442\u043E\u0432 \u0434\u0430\u0442\u044B \u043C\u043E\u0436\u043D\u043E \u0441\u043E\u0437\u0434\u0430\u0442\u044C \u0432\u0430\u043B\u0438\u0434\u043D\u044B\u0439 \u044D\u043A\u0437\u0435\u043C\u043F\u043B\u044F\u0440 \u043D\u0430\u0442\u0438\u0432\u043D\u043E\u0433\u043E \u043E\u0431\u044A\u0435\u043A\u0442\u0430 ", /*#__PURE__*/
      _react.default.createElement("code", null, "Date()")
      )
      ), /*#__PURE__*/
      _react.default.createElement(_Checkbox.Checkbox, { disabled: true, checked: internalDate.validate({ checks: [_types.InternalDateValidateCheck.Range] }) }, "\u2B73 ", /*#__PURE__*/
      _react.default.createElement("code", { style: { color: 'black' } }, "Range"), /*#__PURE__*/
      _react.default.createElement("div", null, "\u0414\u0430\u0442\u0430 \u043D\u0435 \u0432\u044B\u0445\u043E\u0434\u0438\u0442 \u0437\u0430 \u043F\u0440\u0435\u0434\u0435\u043B\u044B \u0434\u0438\u0430\u043F\u0430\u0437\u043E\u043D\u043E\u0432 ", /*#__PURE__*/
      _react.default.createElement("code", null, "minDate/maxDate")
      )
      )
      ));

  };return ViewDateInputValidateChecks;}(_react.default.Component);