"use strict";
Object.defineProperty(exports, "__esModule", {
    value: true
});
function _export(target, all) {
    for(var name in all)Object.defineProperty(target, name, {
        enumerable: true,
        get: Object.getOwnPropertyDescriptor(all, name).get
    });
}
_export(exports, {
    get Default () {
        return Default;
    },
    get Double () {
        return Double;
    },
    get DoubleRange () {
        return DoubleRange;
    }
});
var _react = /*#__PURE__*/ _interop_require_default(require("react"));
var _ = require(".");
function _array_like_to_array(arr, len) {
    if (len == null || len > arr.length) len = arr.length;
    for(var i = 0, arr2 = new Array(len); i < len; i++)arr2[i] = arr[i];
    return arr2;
}
function _array_without_holes(arr) {
    if (Array.isArray(arr)) return _array_like_to_array(arr);
}
function _interop_require_default(obj) {
    return obj && obj.__esModule ? obj : {
        default: obj
    };
}
function _iterable_to_array(iter) {
    if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter);
}
function _non_iterable_spread() {
    throw new TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
}
function _to_consumable_array(arr) {
    return _array_without_holes(arr) || _iterable_to_array(arr) || _unsupported_iterable_to_array(arr) || _non_iterable_spread();
}
function _unsupported_iterable_to_array(o, minLen) {
    if (!o) return;
    if (typeof o === "string") return _array_like_to_array(o, minLen);
    var n = Object.prototype.toString.call(o).slice(8, -1);
    if (n === "Object" && o.constructor) n = o.constructor.name;
    if (n === "Map" || n === "Set") return Array.from(n);
    if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _array_like_to_array(o, minLen);
}
var defaultProps = {
    min: new Date(2022, 4, 0),
    max: new Date(2022, 6, 15),
    date: new Date(),
    isDouble: false,
    isRange: false,
    value: new Date(2022, 5, 6),
    valueRange: [
        new Date(2022, 5, 6),
        new Date(2022, 5, 10)
    ]
};
var eventsRange = _to_consumable_array(new Array(10)).map(function(_, day) {
    return {
        date: new Date(2022, 5, 15 + day),
        color: 'purple'
    };
});
var disabledDays = _to_consumable_array(new Array(5)).map(function(_, day) {
    return {
        date: new Date(2022, 5, 11 + day)
    };
});
var date = {
    day: 1,
    monthIndex: 2,
    year: 2022
};
var onChangeValue = function() {};
var Default = function() {
    var min = defaultProps.min, max = defaultProps.max, isDouble = defaultProps.isDouble, isRange = defaultProps.isRange, value = defaultProps.value;
    return /*#__PURE__*/ _react.default.createElement(_.Calendar, {
        isRange: isRange,
        isDouble: isDouble,
        date: date,
        value: value,
        eventList: eventsRange,
        disabledList: disabledDays,
        min: min,
        max: max,
        onChangeValue: onChangeValue
    });
};
var doubleProps = {
    min: new Date(2022, 4, 0),
    max: new Date(2022, 6, 15),
    value: new Date(2022, 5, 6)
};
var Double = function() {
    var min = doubleProps.min, max = doubleProps.max, value = doubleProps.value;
    return /*#__PURE__*/ _react.default.createElement(_.CalendarDouble, {
        value: value,
        eventList: eventsRange,
        disabledList: disabledDays,
        min: min,
        max: max,
        onChangeValue: onChangeValue
    });
};
var doubleRangeProps = {
    min: new Date(2022, 4, 0),
    max: new Date(2022, 7, 15),
    values: [
        new Date(2022, 5, 7),
        new Date(2022, 6, 9)
    ]
};
var eventList = _to_consumable_array(eventsRange);
var disabledList = _to_consumable_array(disabledDays);
var valueDate = [
    new Date(),
    new Date()
];
var DoubleRange = function() {
    var min = doubleRangeProps.min, max = doubleRangeProps.max;
    return /*#__PURE__*/ _react.default.createElement(_.CalendarDoubleRange, {
        value: valueDate,
        eventList: eventList,
        disabledList: disabledList,
        min: min,
        max: max,
        onChangeValue: onChangeValue
    });
};
