- Maintenance standardize datetime format to YYYY-MM-DD hh:mm:ss

- Import dayjs extensions one time only
- Maintenance activeCondition centralize
This commit is contained in:
Louis Lam
2022-09-28 00:20:17 +08:00
parent 4002b9f577
commit b1465c0282
14 changed files with 51 additions and 61 deletions

View File

@@ -1,12 +1,7 @@
import dayjs from "dayjs";
import timezone from "dayjs/plugin/timezone";
import utc from "dayjs/plugin/utc";
import timezones from "timezones-list";
import { localeDirection, currentLocale } from "./i18n";
dayjs.extend(utc);
dayjs.extend(timezone);
/**
* Returns the offset from UTC in hours for the current locale.
* @returns {number} The offset from UTC in hours.