Skip to content

Commit 06f1033

Browse files
committed
exported IconKey and Icon enum
1 parent bb32124 commit 06f1033

File tree

3 files changed

+15
-1
lines changed

3 files changed

+15
-1
lines changed

src/iconDrawFunctionMap.ts src/icons.ts

+13
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,19 @@ export type IconKey =
2222
| "snow"
2323
| "wind";
2424

25+
export enum ICON {
26+
CLEAR_DAY = "clear-day",
27+
CLEAR_NIGHT = "clear-night",
28+
CLOUDY = "cloudy",
29+
FOG = "fog",
30+
PARTLY_CLOUDY_DAY = "partly-cloudy-day",
31+
PARTLY_CLOUDY_NIGHT = "partly-cloudy-night",
32+
RAIN = "rain",
33+
SLEET = "sleet",
34+
SNOW = "snow",
35+
WIND = "wind"
36+
}
37+
2538
const iconDrawFunctionMap = new Map<IconKey, DrawFunction>([
2639
["clear-day", iconClearDay],
2740
["clear-night", iconClearNight],

src/index.ts

+1
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
11
export { Skycons } from "./skycons";
2+
export { IconKey, ICON } from "./icons";

src/skycons.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { KEYFRAME } from "./constants";
22
import { DrawFunction } from "./DrawFunction";
3-
import { getIconDrawingFunctionByName, IconKey } from "./iconDrawFunctionMap";
3+
import { getIconDrawingFunctionByName, IconKey } from "./icons";
44

55
export interface IConstructorOptions {
66
color: string;

0 commit comments

Comments
 (0)