blob: 598f14d45f6453710df5ceab602e6c5880fe630b (
plain)
1
2
3
4
5
6
7
8
9
|
import { secondsToHours } from '~/lib/utils/datetime_utility';
export const freezePeriodsFixture = getJSONFixture('/api/freeze-periods/freeze_periods.json');
export const timezoneDataFixture = getJSONFixture('/timezones/short.json');
export const findTzByName = (identifier = '') =>
timezoneDataFixture.find(({ name }) => name.toLowerCase() === identifier.toLowerCase());
export const formatTz = ({ offset, name }) => `[UTC ${secondsToHours(offset)}] ${name}`;
|