import React from "react";
import cls from "classnames";
import { classes } from "../../DateTimePicker.tokens";
import { StyledSeparator } from "../Popover/Popover.styles";
import { ShortcutItem, ShortcutList, ShortcutsWrapper, ShortcutTitle, ShortcutTitleWrapper, StyledCell } from "./DateShortcutList.styles";
export const DateShortcutList = ({ items, calendarContainerHeight, dateShortcutsPlacement, dateShortcutsWidth, setShortcutDate, ...rest })=>{
    return /*#__PURE__*/ React.createElement(ShortcutsWrapper, {
        innerHeight: calendarContainerHeight,
        dateShortcutsPlacement: dateShortcutsPlacement,
        ...rest
    }, /*#__PURE__*/ React.createElement(StyledSeparator, null), /*#__PURE__*/ React.createElement(ShortcutList, {
        width: dateShortcutsWidth
    }, items.map((item)=>/*#__PURE__*/ React.createElement(ShortcutItem, {
            tabIndex: item.disabled ? -1 : 0,
            className: cls({
                [classes.shortcutItemDisabled]: item.disabled
            }),
            onClick: ()=>setShortcutDate(item.value)
        }, /*#__PURE__*/ React.createElement(StyledCell, {
            contentLeft: item.contentLeft,
            contentRight: item.contentRight,
            stretching: "filled"
        }, /*#__PURE__*/ React.createElement(ShortcutTitleWrapper, null, /*#__PURE__*/ React.createElement(ShortcutTitle, null, item.label)))))));
};
