"use strict";
Object.defineProperty(exports, "__esModule", {
    value: true
});
Object.defineProperty(exports, "DateShortcutList", {
    enumerable: true,
    get: function() {
        return DateShortcutList;
    }
});
const _react = /*#__PURE__*/ _interop_require_default(require("react"));
const _classnames = /*#__PURE__*/ _interop_require_default(require("classnames"));
const _DateTimePickertokens = require("../../DateTimePicker.tokens");
const _Popoverstyles = require("../Popover/Popover.styles");
const _DateShortcutListstyles = require("./DateShortcutList.styles");
function _interop_require_default(obj) {
    return obj && obj.__esModule ? obj : {
        default: obj
    };
}
const DateShortcutList = ({ items, calendarContainerHeight, dateShortcutsPlacement, dateShortcutsWidth, setShortcutDate, ...rest })=>{
    return /*#__PURE__*/ _react.default.createElement(_DateShortcutListstyles.ShortcutsWrapper, {
        innerHeight: calendarContainerHeight,
        dateShortcutsPlacement: dateShortcutsPlacement,
        ...rest
    }, /*#__PURE__*/ _react.default.createElement(_Popoverstyles.StyledSeparator, null), /*#__PURE__*/ _react.default.createElement(_DateShortcutListstyles.ShortcutList, {
        width: dateShortcutsWidth
    }, items.map((item)=>/*#__PURE__*/ _react.default.createElement(_DateShortcutListstyles.ShortcutItem, {
            tabIndex: item.disabled ? -1 : 0,
            className: (0, _classnames.default)({
                [_DateTimePickertokens.classes.shortcutItemDisabled]: item.disabled
            }),
            onClick: ()=>setShortcutDate(item.value)
        }, /*#__PURE__*/ _react.default.createElement(_DateShortcutListstyles.StyledCell, {
            contentLeft: item.contentLeft,
            contentRight: item.contentRight,
            stretching: "filled"
        }, /*#__PURE__*/ _react.default.createElement(_DateShortcutListstyles.ShortcutTitleWrapper, null, /*#__PURE__*/ _react.default.createElement(_DateShortcutListstyles.ShortcutTitle, null, item.label)))))));
};
