/**
 * DevExtreme (esm/renovation/ui/scheduler/timeZoneCalculator/createTimeZoneCalculator.js)
 * Version: 23.1.8 (build 24063-0109)
 * Build date: Sun Mar 03 2024
 *
 * Copyright (c) 2012 - 2024 Developer Express Inc. ALL RIGHTS RESERVED
 * Read about DevExtreme licensing here: https://js.devexpress.com/Licensing/
 */
import {
    TimeZoneCalculator
} from "./utils";
import timeZoneUtils from "../../../../__internal/scheduler/m_utils_time_zone";
export var createTimeZoneCalculator = currentTimeZone => new TimeZoneCalculator({
    getClientOffset: date => timeZoneUtils.getClientTimezoneOffset(date),
    tryGetCommonOffset: date => timeZoneUtils.calculateTimezoneByValue(currentTimeZone, date),
    tryGetAppointmentOffset: (date, appointmentTimezone) => timeZoneUtils.calculateTimezoneByValue(appointmentTimezone, date)
});
