import { isSameDay, isSameWeek, isSameMonth, isSameQuarter, isSameYear, startOfDay, endOfDay, startOfWeek, endOfWeek, startOfMonth, endOfMonth, startOfQuarter, endOfQuarter, startOfYear, endOfYear, addDays, addMonths, addQuarters, addYears, setDate, getDate, setWeek, getWeek, setMonth, getMonth, setQuarter, getQuarter, setYear, getYear, } from 'date-fns';
export var dateConfig = {
    date: {
        set: setDate,
        get: getDate,
        offsetDate: addDays,
        isSame: isSameDay,
        startDate: startOfDay,
        endDate: endOfDay,
    },
    week: {
        set: setWeek,
        get: getWeek,
        offsetDate: addDays,
        isSame: isSameWeek,
        startDate: startOfWeek,
        endDate: endOfWeek,
    },
    month: {
        set: setMonth,
        get: getMonth,
        offsetDate: addMonths,
        isSame: function (dateLeft, dateRight) {
            return isSameYear(dateLeft, dateRight) && isSameMonth(dateLeft, dateRight);
        },
        startDate: startOfMonth,
        endDate: endOfMonth,
    },
    quarter: {
        set: setQuarter,
        get: getQuarter,
        offsetDate: addQuarters,
        isSame: function (dateLeft, dateRight) {
            return isSameYear(dateLeft, dateRight) && isSameQuarter(dateLeft, dateRight);
        },
        startDate: startOfQuarter,
        endDate: endOfQuarter,
    },
    year: {
        set: setYear,
        get: getYear,
        offsetDate: addYears,
        isSame: isSameYear,
        startDate: startOfYear,
        endDate: endOfYear,
    },
};
