@devexperts/dxcharts-lite
Version:
21 lines (20 loc) • 890 B
JavaScript
/*
* Copyright (C) 2019 - 2025 Devexperts Solutions IE Limited
* This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0.
* If a copy of the MPL was not distributed with this file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/
// eslint-disable-next-line @typescript-eslint/no-unused-vars
const weekWeekday = 'week-weekday';
const timeFormatsConfirugable = ['second', 'minute', 'hour', 'day', 'month', 'year'];
const timeFormatsNoNConfirugable = ['lessThanSecond'];
//#region `ParsedTimeFormat` guards
export const timeFormatConfirugableGuard = (key) => {
return timeFormatsConfirugable.some(type => type === key);
};
export const weekWeekdayGuard = (key) => {
return key === 'week-weekday';
};
export const timeFormatNoNConfirugableGuard = (key) => {
return timeFormatsNoNConfirugable.some(type => type === key);
};
//#endregion guards