forked from filipdanic/compact-timezone-list
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.d.ts
38 lines (37 loc) · 1.34 KB
/
index.d.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
/**
* @fileoverview
*
* This package contains an array of timezones based on conventional options found online.
* It does not follow any complete data set, but all names are according to the tz format:
* https://en.wikipedia.org/wiki/List_of_tz_database_time_zones.
*
* Install:
* `npm install compact-timezone-list --save`
* # or
* `yarn add compact-timezone-list`
*
*
* Example:
* import { defaultTimezoneSet } from 'compact-timezone-list';
* // or
* import { minimalTimezoneSet } from 'compact-timezone-list';
*
* Details:
* - The 'defaultTimezoneSet' export provides a long list of options, with multiple
* suggestions for each UTC offset.
* – The `minimalTimezoneSet` export provides one option per offset type, with
* a favourite chosen to represent each offset. This is mostly targeted to small,
* western-focused apps. But, every UTC offset is included.
*/
export interface TimezoneEntry {
/** a string from '-11:00' to '+14:00' representing the UTC offset */
offset: string;
/** a readable label that contains the offset and a longer, descriptive name of the timezone */
text: string;
/** id of the timezone */
id: string;
/** the value from the tz standard */
category: string;
}
export declare var defaultTimezoneSet: TimezoneEntry[];
export declare var minimalTimezoneSet: TimezoneEntry[];