"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.getLeftBorderRadius = void 0;
const getLeftBorderRadius = ({ isHovered, isInHoveredRange, isPreviousItemInSelectedRange, isNextItemInSelectedRange, isPreviousItemInHoveredRange, selected, theme, }) => {
    if (selected && isPreviousItemInHoveredRange) {
        return isNextItemInSelectedRange ? theme.shape.medium : '0';
    }
    if (selected && !isPreviousItemInSelectedRange) {
        return theme.shape.medium;
    }
    if (isHovered &&
        !isPreviousItemInHoveredRange &&
        !isPreviousItemInSelectedRange) {
        return theme.shape.medium;
    }
    if (isInHoveredRange) {
        // Проверка на последнюю дату
        if (isPreviousItemInHoveredRange === undefined &&
            isPreviousItemInSelectedRange === undefined) {
            return '0';
        }
        if (!isPreviousItemInHoveredRange && !isPreviousItemInSelectedRange) {
            return theme.shape.medium;
        }
    }
    return '0';
};
exports.getLeftBorderRadius = getLeftBorderRadius;
