import BigNumber from 'bignumber.js'; import type { RouteMeta, RouteRecordName } from 'vue-router'; export interface RouteRecordBase { /** * Path of the record. Should start with `/` unless the record is the child of * another record. * * @example `/users/:id` matches `/users/1` as well as `/users/posva`. */ path: string; /** * Name for the route record. */ name: RouteRecordName; /** * Arbitrary data attached to the record. */ meta?: RouteMeta; } export class TimeZone { offsetHour: number; offsetMinite: number; value = 0; constructor(hour = 0, minite = 0) { this.offsetHour = hour; this.offsetMinite = minite; const data = new BigNumber(hour || 0); const value: number = data .times(60) .minus(minite || 0) .toNumber(); this.value = isNaN(value) ? 0 : value; } }