@windycom/plugin-devtools 2.0.0 → 3.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (143) hide show
  1. package/README.md +4 -0
  2. package/index.mjs +2 -2
  3. package/package.json +2 -3
  4. package/types/client/AccessProducts.d.ts +8 -0
  5. package/types/client/BottomSlide.d.ts +3 -0
  6. package/types/client/BottomSveltePlugins.d.ts +8 -0
  7. package/types/client/Calendar.d.ts +9 -17
  8. package/types/client/Color.d.ts +44 -91
  9. package/types/client/EcmwfProduct.d.ts +0 -22
  10. package/types/client/Evented.d.ts +4 -0
  11. package/types/client/ExternalSveltePlugin.d.ts +8 -2
  12. package/types/client/IDB.d.ts +69 -0
  13. package/types/client/IconProducts.d.ts +2 -0
  14. package/types/client/Layer.d.ts +1 -2
  15. package/types/client/Metric.d.ts +13 -9
  16. package/types/client/MetricClasses.d.ts +4 -3
  17. package/types/client/Overlay.d.ts +31 -16
  18. package/types/client/OverlayClasses.d.ts +11 -7
  19. package/types/client/Plugin.d.ts +6 -2
  20. package/types/client/Product.d.ts +33 -30
  21. package/types/client/RadarPlusProduct.d.ts +19 -0
  22. package/types/client/Renderer.d.ts +2 -10
  23. package/types/client/SatelliteProduct.d.ts +1 -1
  24. package/types/client/SveltePlugin.d.ts +16 -5
  25. package/types/client/TileLayer.d.ts +1 -2
  26. package/types/client/TopoMap.d.ts +10 -0
  27. package/types/client/WindowPlugin.d.ts +9 -4
  28. package/types/client/appsFlyer.d.ts +2 -0
  29. package/types/client/baseMap.d.ts +8 -5
  30. package/types/client/cityLabels.d.ts +10 -2
  31. package/types/client/cloudSync.d.ts +3 -1
  32. package/types/client/colorGradients.d.ts +13 -0
  33. package/types/client/compatibilityCheck.d.ts +1 -0
  34. package/types/client/connection.d.ts +1 -1
  35. package/types/client/customColors.d.ts +1 -0
  36. package/types/client/d.ts.files/Calendar.d.ts +11 -2
  37. package/types/client/d.ts.files/Color.d.ts +17 -5
  38. package/types/client/d.ts.files/LabelsLayer.d.ts +3 -20
  39. package/types/client/d.ts.files/Layer.d.ts +8 -1
  40. package/types/client/d.ts.files/Metric.d.ts +1 -0
  41. package/types/client/d.ts.files/Renderer.d.ts +22 -1
  42. package/types/client/d.ts.files/alerts.d.ts +119 -0
  43. package/types/client/d.ts.files/broadcast.d.ts +51 -18
  44. package/types/client/d.ts.files/dataSpecifications.d.ts +121 -137
  45. package/types/client/d.ts.files/favs.d.ts +68 -0
  46. package/types/client/d.ts.files/incomingMessages.d.ts +0 -4
  47. package/types/client/d.ts.files/lib.d.ts +5 -7
  48. package/types/client/d.ts.files/notifications.d.ts +2 -2
  49. package/types/client/d.ts.files/plugin-params.d.ts +53 -57
  50. package/types/client/d.ts.files/plugins.d.ts +31 -42
  51. package/types/client/d.ts.files/pois.d.ts +1 -1
  52. package/types/client/d.ts.files/products.d.ts +16 -5
  53. package/types/client/d.ts.files/rootScope.d.ts +13 -31
  54. package/types/client/d.ts.files/startup.d.ts +65 -0
  55. package/types/client/d.ts.files/storage.d.ts +12 -35
  56. package/types/client/d.ts.files/user.d.ts +82 -24
  57. package/types/client/detectDevice.d.ts +0 -3
  58. package/types/client/device.d.ts +1 -0
  59. package/types/client/deviceLogging.d.ts +2 -1
  60. package/types/client/embed.d.ts +70 -0
  61. package/types/client/embed2.d.ts +14 -31
  62. package/types/client/errorLogger.d.ts +28 -3
  63. package/types/client/errors.d.ts +6 -0
  64. package/types/client/fetch.d.ts +41 -16
  65. package/types/client/format.d.ts +1 -1
  66. package/types/client/ga.d.ts +1 -1
  67. package/types/client/geolocation.d.ts +15 -7
  68. package/types/client/globals.d.ts +1 -0
  69. package/types/client/http.d.ts +17 -6
  70. package/types/client/idbInstances.d.ts +36 -0
  71. package/types/client/imaker.d.ts +112 -0
  72. package/types/client/imakerMain.d.ts +49 -0
  73. package/types/client/langFiles.d.ts +2 -0
  74. package/types/client/latestBroadcasts.d.ts +1 -1
  75. package/types/client/layers.d.ts +2 -0
  76. package/types/client/lib.d.ts +6 -22
  77. package/types/client/libHtml.d.ts +1 -1
  78. package/types/client/liveAlerts.d.ts +5 -0
  79. package/types/client/liveAlerts.types.d.ts +28 -0
  80. package/types/client/loadArticlesOrWhatsNew.d.ts +1 -0
  81. package/types/client/location.d.ts +5 -0
  82. package/types/client/log.d.ts +4 -1
  83. package/types/client/lruCache.d.ts +6 -0
  84. package/types/client/map.d.ts +17 -6
  85. package/types/client/mobile.d.ts +31 -22
  86. package/types/client/models.d.ts +7 -5
  87. package/types/client/notifications.d.ts +29 -67
  88. package/types/client/overlays.d.ts +4 -1
  89. package/types/client/params.d.ts +0 -1
  90. package/types/client/permanentPromos.d.ts +1 -1
  91. package/types/client/persistentStorage.d.ts +8 -0
  92. package/types/client/picker.d.ts +1 -1
  93. package/types/client/plugins.d.ts +4 -0
  94. package/types/client/pois.d.ts +1 -2
  95. package/types/client/promo.d.ts +6 -16
  96. package/types/client/pushNotifications.d.ts +1 -1
  97. package/types/client/queryString.d.ts +1 -1
  98. package/types/client/renderUtils.d.ts +1 -1
  99. package/types/client/renderers.d.ts +7 -3
  100. package/types/client/rootScope.d.ts +23 -24
  101. package/types/client/router.d.ts +9 -29
  102. package/types/client/seoParser.d.ts +0 -14
  103. package/types/client/serviceWorkerCtrl.d.ts +8 -0
  104. package/types/client/showableErrorsService.d.ts +6 -10
  105. package/types/client/startupWeather.d.ts +13 -9
  106. package/types/client/store.d.ts +2 -2
  107. package/types/client/storeLastPosition.d.ts +4 -0
  108. package/types/client/subscription.d.ts +1 -0
  109. package/types/client/swDownloader.d.ts +7 -7
  110. package/types/client/swProxy.d.ts +1 -1
  111. package/types/client/swUtils.d.ts +3 -3
  112. package/types/client/trans.d.ts +26 -37
  113. package/types/client/user.d.ts +7 -13
  114. package/types/client/userAlerts.d.ts +68 -0
  115. package/types/client/userConsent.d.ts +6 -0
  116. package/types/client/userFavs.d.ts +46 -122
  117. package/types/client/utils.d.ts +67 -9
  118. package/types/iconfont.d.ts +8 -0
  119. package/types/interfaces.d.ts +226 -284
  120. package/types/lang-files.d.ts +1334 -142
  121. package/types/offline.d.ts +100 -0
  122. package/types/types.d.ts +108 -34
  123. package/types/client/Bar.d.ts +0 -114
  124. package/types/client/BindedBar.d.ts +0 -51
  125. package/types/client/BindedCheckbox.d.ts +0 -30
  126. package/types/client/BindedSwitch.d.ts +0 -35
  127. package/types/client/BottomTagPlugin.d.ts +0 -8
  128. package/types/client/DraggableDiv.d.ts +0 -21
  129. package/types/client/GhostBox.d.ts +0 -17
  130. package/types/client/Legend.d.ts +0 -6
  131. package/types/client/LongTap.d.ts +0 -21
  132. package/types/client/MobileCalendar.d.ts +0 -51
  133. package/types/client/OfflineMessagesClasses.d.ts +0 -30
  134. package/types/client/ProductSwitch.d.ts +0 -14
  135. package/types/client/Scrollable.d.ts +0 -14
  136. package/types/client/Switch.d.ts +0 -24
  137. package/types/client/TimestampBar.d.ts +0 -8
  138. package/types/client/d.ts.files/Product.d.ts +0 -37
  139. package/types/client/d.ts.files/errorLogger.d.ts +0 -35
  140. package/types/client/d.ts.files/trans.d.ts +0 -55
  141. package/types/client/favs.d.ts +0 -83
  142. package/types/client/offlineController.d.ts +0 -20
  143. /package/types/client/d.ts.files/{Webcams.d.ts → webcams.d.ts} +0 -0
@@ -1,67 +1,29 @@
1
- import { Evented } from '@windy/Evented';
2
- import * as http from '@windy/http';
3
- import type { HttpPayload } from './d.ts.files/http.d';
4
- import type { NotificationInfo } from './d.ts.files/notifications.d';
5
- declare class Notification extends Evented<Notification> {
6
- data: Record<string, unknown>;
7
- eventSource: null | EventSource;
8
- canReceiveNotif: boolean;
9
- hasUnloadListener: boolean;
10
- constructor();
11
- /**
12
- * Close SSE event stream
13
- */
14
- clean(): void;
15
- /**
16
- * Connect to SSE event stream and hook all event listeners
17
- */
18
- watchChanges(): void;
19
- /**
20
- * Get notifications list (paging is applied)
21
- *
22
- * @param currentPage Page number to get
23
- * @param pageSize Page size to include into list
24
- * @returns Page is updated with received data or error is shown if anything failed
25
- */
26
- loadNotificationList(currentPage: number, pageSize: number): Promise<void | NotificationInfo>;
27
- /**
28
- * Mark alert as seen by its id. This may affect more notifications if the alert has some.
29
- *
30
- * @param id Alert id
31
- * @returns
32
- */
33
- markAlertAsSeen(id: string): Promise<HttpPayload<void>>;
34
- /**
35
- * Mark notification as seen by its id. It affects just and only one specific notification.
36
- *
37
- * @param id Notification id
38
- * @returns
39
- */
40
- markNotificationAsSeen(id: string): Promise<http.HttpPayload<void>>;
41
- /**
42
- * Mark all notifications ad received (= not seen yet, but already delivered)
43
- *
44
- * @returns
45
- */
46
- markNotificationsAsReceived(): Promise<void | http.HttpPayload<void>>;
47
- /**
48
- * Delete all users notifications
49
- *
50
- * @returns
51
- */
52
- deleteAllNotifications(): Promise<http.HttpPayload<void>>;
53
- /**
54
- * Mark all users notifications as seen
55
- */
56
- markAllAsSeen(): void;
57
- /**
58
- * Update notification state. It updates store value so all necessary events are triggered.
59
- *
60
- * @param vals `totalCount` and `newCount` values to set
61
- * @param vals.totalCount Total count of all notifications (already seen is included)
62
- * @param vals.newCount Count of new unseen notifications
63
- */
64
- updateInfo({ totalCount, newCount }: NotificationInfo): void;
65
- }
66
- declare const _default: Notification;
67
- export default _default;
1
+ import type { NotificationExtraPayload } from './d.ts.files/pushNotifications';
2
+ import type { HttpPayload } from './d.ts.files/http';
3
+ export declare const canReceiveNotifications: Promise<void>;
4
+ export declare function loadNotifications(): Promise<void>;
5
+ export declare function watchChanges(): void;
6
+ /**
7
+ * Delete all users notifications
8
+ */
9
+ export declare function deleteAllNotifications(): Promise<void>;
10
+ /**
11
+ * Mark notification as seen
12
+ *
13
+ * @param id Alert id
14
+ * @param processId Process id
15
+ */
16
+ export declare function markNotificationAsSeen(data: NotificationExtraPayload): Promise<HttpPayload<void>>;
17
+ /**
18
+ * Mark notification as received
19
+ *
20
+ * @param id Alert id
21
+ * @param processId Process id
22
+ */
23
+ export declare function markNotificationAsReceived(data: NotificationExtraPayload): Promise<HttpPayload<void>>;
24
+ /**
25
+ * After this BE will send notification to device
26
+ * @param type
27
+ * @param device
28
+ */
29
+ export declare function sendTestNotification(type: NotificationExtraPayload['category'], registrationHash: string, deviceID: string): void;
@@ -47,9 +47,9 @@ declare const overlays: {
47
47
  dustsm: Overlay<"dustsm", import("../weatherClasses/MetricClasses").NumberedMetric, import("../weatherClasses/Layer").Layer<import("../weatherClasses/MetricClasses").NumberedMetric>>;
48
48
  ptype: RainPtypeOverlay<"ptype">;
49
49
  ccl: Overlay<"ccl", import("../weatherClasses/MetricClasses").NumberedMetric, import("../weatherClasses/Layer").Layer<import("../weatherClasses/MetricClasses").NumberedMetric>>;
50
- gh: Overlay<"gh", import("../weatherClasses/MetricClasses").NumberedMetric, import("../weatherClasses/Layer").Layer<import("../weatherClasses/MetricClasses").NumberedMetric>>;
51
50
  radar: Overlay<"radar", import("../weatherClasses/MetricClasses").NumberedMetric, import("../weatherClasses/Layer").Layer<import("../weatherClasses/MetricClasses").NumberedMetric>>;
52
51
  satellite: Overlay<"satellite", import("../weatherClasses/MetricClasses").NumberedMetric, import("../weatherClasses/Layer").Layer<import("../weatherClasses/MetricClasses").NumberedMetric>>;
52
+ radarPlus: Overlay<"radarPlus", import("../weatherClasses/MetricClasses").NumberedMetric, import("../weatherClasses/Layer").Layer<import("../weatherClasses/MetricClasses").NumberedMetric>>;
53
53
  satelliteIRBT: Overlay<"satellite", import("../weatherClasses/MetricClasses").NumberedMetric, import("../weatherClasses/Layer").Layer<import("../weatherClasses/MetricClasses").NumberedMetric>>;
54
54
  capAlerts: Overlay<"capAlerts", undefined, import("../weatherClasses/Layer").Layer<undefined>>;
55
55
  efiWind: Overlay<"efiWind", import("../weatherClasses/MetricClasses").NumberedMetric, import("../weatherClasses/Layer").Layer<import("../weatherClasses/MetricClasses").NumberedMetric>>;
@@ -63,5 +63,8 @@ declare const overlays: {
63
63
  soilMoisture100: Overlay<"soilMoisture100", import("../weatherClasses/MetricClasses").NumberedMetric, import("../weatherClasses/Layer").Layer<import("../weatherClasses/MetricClasses").NumberedMetric>>;
64
64
  fwi: FwiOverlay<"fwi">;
65
65
  dfm10h: Overlay<"dfm10h", import("../weatherClasses/MetricClasses").NumberedMetric, import("../weatherClasses/Layer").Layer<import("../weatherClasses/MetricClasses").NumberedMetric>>;
66
+ heatmaps: Overlay<"heatmaps", undefined, undefined>;
67
+ topoMap: Overlay<"topoMap", undefined, import("../weatherClasses/Layer").Layer<undefined>>;
68
+ hurricanes: Overlay<"hurricanes", undefined, undefined>;
66
69
  };
67
70
  export default overlays;
@@ -1,2 +1 @@
1
1
  import '@windy/renderCtrl';
2
- import '@windy/router';
@@ -1 +1 @@
1
- export declare const neverDisplayLongTapPromo: () => void;
1
+ export {};
@@ -0,0 +1,8 @@
1
+ declare class PersistentStorage {
2
+ private readonly internalStorage;
3
+ constructor();
4
+ getItem(key: string): Promise<string | null>;
5
+ setItem(key: string, value: string): Promise<void>;
6
+ }
7
+ export declare const persistentStorage: PersistentStorage;
8
+ export {};
@@ -32,7 +32,7 @@ export declare class PickerDot {
32
32
  * Locks picker in position, so any change in picker location
33
33
  * will sync its position to desired lat,lons
34
34
  */
35
- lockPosition(): void;
35
+ lockPosition(): LatLon;
36
36
  unlockPosition(): void;
37
37
  /**
38
38
  * Sets & lock the position of picker dot
@@ -1,3 +1,7 @@
1
1
  import type { Plugins } from './d.ts.files/plugins.d';
2
2
  declare const plugins: Plugins;
3
+ /**
4
+ * Promise resolves once installed external plugins have loaded into default export
5
+ */
6
+ export declare const externalPluginsLoaded: Promise<void>;
3
7
  export default plugins;
@@ -11,6 +11,5 @@ import type { PoisCheckboxes } from './d.ts.files/pois.d';
11
11
  export declare const poisCheckboxes: PoisCheckboxes;
12
12
  /**
13
13
  * Is there something to display on map as a POI
14
- * TODO: Make sure Alerts are included in favs too by creating alert on map
15
14
  */
16
- export declare const displayPoiOnMap: () => boolean;
15
+ export declare const displayPoiOnMap: () => Promise<boolean>;
@@ -1,27 +1,17 @@
1
- import type { StorageData } from '@windy/storage.d';
1
+ import type { Timestamp } from '@windy/types';
2
2
  export interface PromoInfoObject {
3
+ id: string;
3
4
  displayed: number;
4
- ts: number;
5
+ ts: Timestamp;
5
6
  }
6
7
  /**
7
- * Get raw promo object from localStorage
8
- *
9
- * @returns Local promos
10
- */
11
- export declare const getAll: () => StorageData['promos2'];
12
- /**
13
- * Get basic info about promo
14
- *
15
- * @param ident Identification
16
- * @returns Promo info object
8
+ * Get basic info about promo for given ident
17
9
  */
18
- export declare const getCounter2: (ident: string) => PromoInfoObject;
10
+ export declare const getCounter: (id: string) => Promise<PromoInfoObject>;
19
11
  /**
20
12
  * Increases 'seen' counter for particular promo
21
- *
22
- * @param ident Ident
23
13
  */
24
- export declare const hitCounter: (ident: string) => void;
14
+ export declare const hitCounter: (id: string, logEvent?: boolean) => Promise<void>;
25
15
  /**
26
16
  * Flag the promo to be never seen again (by setting
27
17
  * its number to 1000)
@@ -1 +1 @@
1
- export declare function registerDevice(): Promise<string | unknown>;
1
+ export declare const registerDevice: () => Promise<null>;
@@ -1,2 +1,2 @@
1
- export type ParsedQueryString = Record<string, string>;
1
+ export type ParsedQueryString = Record<string, string | undefined>;
2
2
  export declare function parseQueryString(searchQuery: string | undefined): ParsedQueryString | undefined;
@@ -5,7 +5,7 @@ import { Evented } from '@windy/Evented';
5
5
  import type { Color } from '@windy/Color';
6
6
  import type { Layer } from '@windy/Layer';
7
7
  import type { FullRenderParameters } from '@windy/Layer.d';
8
- import type { DataQuality } from '@windy/Product.d';
8
+ import type { DataQuality } from '@windy/Product';
9
9
  import type { TileParams } from '@windy/Renderer.d';
10
10
  import type { TilePoint } from '@windy/interfaces.d';
11
11
  interface Events {
@@ -1,4 +1,5 @@
1
1
  import { Renderer } from '@windy/Renderer';
2
+ import { TopoMap } from '@windy/TopoMap';
2
3
  import { TileLayer } from '@windy/TileLayer';
3
4
  declare const renderers: {
4
5
  /**
@@ -8,13 +9,16 @@ declare const renderers: {
8
9
  */
9
10
  tileLayer: TileLayer;
10
11
  noUserControl: TileLayer;
11
- radar: Renderer<"radar", typeof import("../../plugins/radar/radar")>;
12
- satellite: Renderer<"satellite", typeof import("../../plugins/satellite/satellite")>;
13
- capAlerts: Renderer<"cap-alerts", typeof import("../../plugins/cap-alerts/cap-alerts")>;
12
+ radar: Renderer<"radar", any>;
13
+ satellite: Renderer<"satellite", any>;
14
+ radarPlus: Renderer<"radar-plus", any>;
15
+ capAlerts: Renderer<"cap-alerts", typeof import("../pluginSystem/SveltePlugin").SvelteApp & typeof import("../../plugins/cap-alerts/cap-alerts")>;
14
16
  isolines: Renderer<"isolines", typeof import("../../plugins/isolines/isolines")>;
15
17
  particles: Renderer<"gl-particles", typeof import("../../plugins/gl-particles/gl-particles")> | Renderer<"particles", typeof import("../../plugins/particles/particles")>;
16
18
  /** Extreme forecast and intersucho layers */
17
19
  daySwitcher: TileLayer;
18
20
  accumulations: TileLayer;
21
+ /** Seznam topographic Map */
22
+ topoMap: TopoMap;
19
23
  };
20
24
  export default renderers;
@@ -1,6 +1,5 @@
1
1
  import type { Iconfont } from './d.ts.files/iconfont';
2
- import type { Isolines, Pois } from './d.ts.files/rootScope.d';
3
- import type { LoadedTranslations } from './d.ts.files/trans.d';
2
+ import type { LoadedTranslations } from './d.ts.files/types';
4
3
  /**
5
4
  * Version of Windy.com client (as taken from package.json)
6
5
  * @ignore
@@ -10,17 +9,17 @@ export declare const version: string;
10
9
  * Target
11
10
  * @ignore
12
11
  */
13
- export declare const target: "mobile" | "index" | "lib" | "embed2";
12
+ export declare const target: "lib" | "embed" | "mobile" | "index" | "imaker";
14
13
  /**
15
14
  * Platform
16
15
  * @ignore
17
16
  */
18
- export declare const platform: import("../../types/types").Platform;
17
+ export declare const platform: import("@windy/types").Platform;
19
18
  /**
20
19
  * Device
21
20
  * @ignore
22
21
  */
23
- export declare const device: import("../../types/types").Device;
22
+ export declare const device: import("@windy/types").Device;
24
23
  /**
25
24
  * List of Windy's supported languages
26
25
  */
@@ -70,27 +69,23 @@ export declare const iconsDir = "<!-- @echo IMG_RELATIVE_PATH -->/icons7";
70
69
  /**
71
70
  * List of valid overlay identifiers
72
71
  */
73
- export declare const overlays: readonly ["radar", "satellite", "wind", "gust", "gustAccu", "turbulence", "icing", "rain", "rainAccu", "snowAccu", "snowcover", "ptype", "thunder", "temp", "dewpoint", "rh", "deg0", "wetbulbtemp", "solarpower", "uvindex", "clouds", "hclouds", "mclouds", "lclouds", "fog", "cloudtop", "cbase", "visibility", "cape", "ccl", "waves", "swell1", "swell2", "swell3", "wwaves", "sst", "currents", "currentsTide", "no2", "pm2p5", "aod550", "gtco3", "tcso2", "go3", "cosc", "dustsm", "pressure", "efiTemp", "efiWind", "efiRain", "capAlerts", "soilMoisture40", "soilMoisture100", "moistureAnom40", "moistureAnom100", "drought40", "drought100", "fwi", "dfm10h"];
74
- /**
75
- * List of valid accumulation times
76
- */
77
- export declare const acTimes: readonly ["next12h", "next24h", "next36h", "next2d", "next48h", "next60h", "next3d", "next5d", "next10d"];
72
+ export declare const overlays: readonly ["radar", "satellite", "radarPlus", "wind", "gust", "gustAccu", "turbulence", "icing", "rain", "rainAccu", "snowAccu", "snowcover", "ptype", "thunder", "temp", "dewpoint", "rh", "deg0", "wetbulbtemp", "solarpower", "uvindex", "clouds", "hclouds", "mclouds", "lclouds", "fog", "cloudtop", "cbase", "visibility", "cape", "ccl", "waves", "swell1", "swell2", "swell3", "wwaves", "sst", "currents", "currentsTide", "no2", "pm2p5", "aod550", "gtco3", "tcso2", "go3", "cosc", "dustsm", "pressure", "efiTemp", "efiWind", "efiRain", "capAlerts", "soilMoisture40", "soilMoisture100", "moistureAnom40", "moistureAnom100", "drought40", "drought100", "fwi", "dfm10h", "heatmaps", "topoMap", "hurricanes"];
78
73
  /**
79
74
  * Identifier of products that cover only certain area
80
75
  */
81
- export declare const localProducts: readonly ["nems", "namConus", "namHawaii", "namAlaska", "iconEu", "iconD2", "arome", "aromeAntilles", "aromeReunion", "canHrdps", "canRdwpsWaves", "camsEu", "iconEuWaves", "hrrrAlaska", "hrrrConus", "bomAccess", "ukv", "jmaMsm", "jmaCwmWaves"];
76
+ export declare const localProducts: readonly ["nems", "namConus", "namHawaii", "namAlaska", "iconEu", "iconD2", "arome", "aromeAntilles", "aromeFrance", "aromeReunion", "canHrdps", "canRdwpsWaves", "camsEu", "czeAladin", "iconEuWaves", "hrrrAlaska", "hrrrConus", "bomAccess", "bomAccessAd", "bomAccessBn", "bomAccessDn", "bomAccessNq", "bomAccessPh", "bomAccessSy", "bomAccessVt", "ukv", "jmaMsm", "jmaCwmWaves"];
82
77
  /**
83
78
  * Identifiers of global products
84
79
  */
85
- export declare const globalProducts: readonly ["gfs", "ecmwf", "ecmwfAnalysis", "ecmwfAifs", "radar", "ecmwfWaves", "gfsWaves", "icon", "iconWaves", "capAlerts", "cams", "efi", "satellite", "cmems", "drought", "fireDanger", "activeFires"];
80
+ export declare const globalProducts: readonly ["gfs", "ecmwf", "ecmwfAnalysis", "radar", "ecmwfWaves", "gfsWaves", "icon", "capAlerts", "cams", "efi", "satellite", "radarPlus", "cmems", "drought", "fireDanger", "activeFires", "topoMap"];
86
81
  /**
87
82
  * Identifiers of sea products
88
83
  */
89
- export declare const seaProducts: readonly ["ecmwfWaves", "gfsWaves", "iconWaves", "iconEuWaves", "canRdwpsWaves", "cmems", "jmaCwmWaves"];
84
+ export declare const seaProducts: readonly ["ecmwfWaves", "gfsWaves", "iconEuWaves", "canRdwpsWaves", "cmems", "jmaCwmWaves"];
90
85
  /**
91
86
  * Identifiers of wave products, if product is not here, it will be considered as air product
92
87
  */
93
- export declare const waveProducts: readonly ["ecmwfWaves", "gfsWaves", "iconWaves", "iconEuWaves", "jmaCwmWaves", "canRdwpsWaves"];
88
+ export declare const waveProducts: readonly ["ecmwfWaves", "gfsWaves", "iconEuWaves", "jmaCwmWaves", "canRdwpsWaves"];
94
89
  /**
95
90
  * identifiers of air quality product
96
91
  */
@@ -98,19 +93,19 @@ export declare const airQualityProducts: readonly ["cams", "camsEu"];
98
93
  /**
99
94
  * identifiers of local products, that have point forecast
100
95
  */
101
- export declare const localPointProducts: readonly ["namConus", "namHawaii", "namAlaska", "iconD2", "iconEu", "iconEuWaves", "arome", "aromeAntilles", "aromeReunion", "canHrdps", "canRdwpsWaves", "hrrrAlaska", "hrrrConus", "bomAccess", "ukv", "jmaMsm", "jmaCwmWaves"];
96
+ export declare const localPointProducts: readonly ["namConus", "namHawaii", "namAlaska", "iconD2", "iconEu", "iconEuWaves", "arome", "aromeAntilles", "aromeFrance", "aromeReunion", "canHrdps", "canRdwpsWaves", "czeAladin", "hrrrAlaska", "hrrrConus", "bomAccess", "bomAccessAd", "bomAccessBn", "bomAccessDn", "bomAccessNq", "bomAccessPh", "bomAccessSy", "bomAccessVt", "ukv", "jmaMsm", "jmaCwmWaves"];
102
97
  /**
103
98
  * Identifiers of global products, that have point forecast
104
99
  */
105
- export declare const globalPointProducts: readonly ["gfs", "ecmwf", "ecmwfAifs", "icon", "mblue"];
100
+ export declare const globalPointProducts: readonly ["gfs", "ecmwf", "icon", "mblue"];
106
101
  /**
107
102
  * Identifiers of all land products combined
108
103
  */
109
- export declare const products: readonly ["gfs", "ecmwf", "ecmwfAnalysis", "ecmwfAifs", "radar", "ecmwfWaves", "gfsWaves", "icon", "iconWaves", "capAlerts", "cams", "efi", "satellite", "cmems", "drought", "fireDanger", "activeFires", "nems", "namConus", "namHawaii", "namAlaska", "iconEu", "iconD2", "arome", "aromeAntilles", "aromeReunion", "canHrdps", "canRdwpsWaves", "camsEu", "iconEuWaves", "hrrrAlaska", "hrrrConus", "bomAccess", "ukv", "jmaMsm", "jmaCwmWaves", "cams", "camsEu", "mblue"];
104
+ export declare const products: readonly ["gfs", "ecmwf", "ecmwfAnalysis", "radar", "ecmwfWaves", "gfsWaves", "icon", "capAlerts", "cams", "efi", "satellite", "radarPlus", "cmems", "drought", "fireDanger", "activeFires", "topoMap", "nems", "namConus", "namHawaii", "namAlaska", "iconEu", "iconD2", "arome", "aromeAntilles", "aromeFrance", "aromeReunion", "canHrdps", "canRdwpsWaves", "camsEu", "czeAladin", "iconEuWaves", "hrrrAlaska", "hrrrConus", "bomAccess", "bomAccessAd", "bomAccessBn", "bomAccessDn", "bomAccessNq", "bomAccessPh", "bomAccessSy", "bomAccessVt", "ukv", "jmaMsm", "jmaCwmWaves", "cams", "camsEu", "mblue"];
110
105
  /**
111
106
  * Identifiers of all point products combines
112
107
  */
113
- export declare const pointProducts: readonly ["gfs", "ecmwf", "ecmwfAifs", "icon", "mblue", "namConus", "namHawaii", "namAlaska", "iconD2", "iconEu", "iconEuWaves", "arome", "aromeAntilles", "aromeReunion", "canHrdps", "canRdwpsWaves", "hrrrAlaska", "hrrrConus", "bomAccess", "ukv", "jmaMsm", "jmaCwmWaves"];
108
+ export declare const pointProducts: readonly ["gfs", "ecmwf", "icon", "mblue", "namConus", "namHawaii", "namAlaska", "iconD2", "iconEu", "iconEuWaves", "arome", "aromeAntilles", "aromeFrance", "aromeReunion", "canHrdps", "canRdwpsWaves", "czeAladin", "hrrrAlaska", "hrrrConus", "bomAccess", "bomAccessAd", "bomAccessBn", "bomAccessDn", "bomAccessNq", "bomAccessPh", "bomAccessSy", "bomAccessVt", "ukv", "jmaMsm", "jmaCwmWaves"];
114
109
  /**
115
110
  * IndicatesIndicates that that browsing device is mobile
116
111
  */
@@ -119,19 +114,23 @@ export declare const isMobile: boolean;
119
114
  * Indicates that browsing device is tablet
120
115
  */
121
116
  export declare const isTablet: boolean;
117
+ /**
118
+ * Indicates that that browsing device is desktop
119
+ */
120
+ export declare const isDesktop: boolean;
122
121
  /**
123
122
  * Indicates that browsing device is mobile or tablet
124
123
  */
125
124
  export declare const isMobileOrTablet: boolean;
125
+ /**
126
+ * Indicates that browsing device is tablet or desktop
127
+ */
128
+ export declare const isDesktopOrTablet: boolean;
126
129
  /**
127
130
  * Indicates that browsing device has retina display
128
131
  * @ignore
129
132
  */
130
133
  export declare const isRetina: boolean;
131
- /**
132
- * Preferred browsers' language (not the used one). Can contain language that is not supported by Windy
133
- */
134
- export declare const prefLang: string;
135
134
  /**
136
135
  * Valid levels, their identifier and display string
137
136
  * @ignore this will crash Markdown parser
@@ -147,12 +146,12 @@ export declare const maxFavPoisDesktop = 7;
147
146
  * Valid POI layers, their name and icon
148
147
  * @ignore this will crash Markdown parser
149
148
  */
150
- export declare const pois: Record<Pois, [keyof LoadedTranslations | string, Iconfont]>;
149
+ export declare const pois: Record<string, [keyof LoadedTranslations | string, Iconfont]>;
151
150
  /**
152
151
  * List of valid isoline identifiers
153
152
  * @ignore this will crash Markdown parser
154
153
  */
155
- export declare const isolines: Isolines[];
154
+ export declare const isolinesType: readonly ["pressure", "gh", "temp", "deg0"];
156
155
  /**
157
156
  * Location of internal Windy plugins
158
157
  * TODO: Mobile apps have probably different location
@@ -1,30 +1,10 @@
1
- import { type ParsedQueryString } from '../utils/queryString';
2
- import type { PluginIdent } from '@windy/Plugin';
3
- import type { Coords, PickerCoords } from '@windy/interfaces.d';
4
- import type { ExternalPluginIdent } from '@windy/types';
5
- type StartupCoords = {
6
- sharedCoords: Coords | null;
7
- pickerCoords: PickerCoords | null;
1
+ export declare const sharedCoords: {
2
+ lat: string;
3
+ lon: string;
4
+ zoom: string | number;
8
5
  };
9
- /**
10
- * Parse URL to plugin and its parameters (if any)
11
- *
12
- * @returns true if some of the plugins was matched, false otherwise
13
- */
14
- export declare function resolveRoute(purl: string, source: 'url' | 'back-button', parsedQs?: ParsedQueryString): ExternalPluginIdent | PluginIdent | void;
15
- /**
16
- * Parse search part of the URL
17
- * eg: https://www.windy.com/?overlay,level,acTime,lat,lon,zoom,marker
18
- * lat,lon,zoom are obligatory and must go always together
19
- * All other params are optional and can be in any order
20
- * WARNING: This method has thousands of side effects!!
21
- *
22
- * @param searchQuery Search part of the URL, eg: lat,lon,zoom,marker
23
- * @returns Coordinates from the URL (if any) and coordinates of the picker (if any)
24
- */
25
- export declare function parseSearch(searchQuery: string | undefined, parsedQs?: ParsedQueryString): StartupCoords | undefined;
26
- /**
27
- * Parsed coordinates from URL
28
- */
29
- export declare const sharedCoords: Coords;
30
- export {};
6
+ export declare const url: () => void;
7
+ export declare const resolveRoute: () => any;
8
+ export declare const parseSearch: () => any;
9
+ export declare const parsedOverlay = "wind";
10
+ export declare const parsedProduct: any;
@@ -1,19 +1,5 @@
1
1
  declare const _default: {
2
- /**
3
- * Language parsed from startupUrl, null if cannot be parsed
4
- */
5
- lang: string;
6
- /**
7
- * Path part of the startup URL without SEO parts
8
- */
9
2
  purl: string;
10
- /**
11
- * Path part of the initial URL when client was open
12
- */
13
3
  startupUrl: string;
14
- /**
15
- * Overlay parsed from startupUrl, null if cannot be parsed
16
- */
17
- overlay: string;
18
4
  };
19
5
  export default _default;
@@ -0,0 +1,8 @@
1
+ import type { ClientMessage } from '../../types/offline';
2
+ /**
3
+ * Sends message to service worker
4
+ */
5
+ export declare const sendMessageToServiceWorker: (message: ClientMessage) => void;
6
+ export declare const installServiceWorker: () => void;
7
+ export declare const isServiceWorkerSupported: () => boolean;
8
+ export declare const getServiceWorkerError: () => string | null;
@@ -1,31 +1,27 @@
1
1
  import type { ErrorCategory, ShowableError } from '@windy/types.d';
2
- /**
3
- * Add showableError to local storage
4
- * @param error
5
- */
6
- export declare const add: (error: ShowableError) => void;
2
+ export declare const add: (_error: ShowableError) => void;
7
3
  /**
8
4
  * Sets showableError to not be displayed anymore
9
5
  * @param errorId
10
6
  */
11
- export declare const close: (errorId: string) => void;
7
+ export declare const close: (_errorId: string) => void;
12
8
  /**
13
9
  * It return array unresolvedErrors with removed showableError
14
10
  * @param errorId
15
11
  */
16
- export declare const resolve: (errorId: string) => void;
12
+ export declare const resolve: (_errorId: string) => void;
17
13
  /**
18
14
  * It resolve whole category of errors from unresolvedErrors
19
15
  * @param category
20
16
  */
21
- export declare const resolveCategory: (category: ErrorCategory) => void;
17
+ export declare const resolveCategory: (_category: ErrorCategory) => void;
22
18
  /**
23
19
  * Returns unresolved errors
24
20
  * @returns ShowableError[]
25
21
  */
26
- export declare const getUnresolvedErrors: () => ShowableError[];
22
+ export declare const getUnresolvedErrors: () => any[];
27
23
  /**
28
24
  * Control if error was resolved, based on category of the error
29
25
  * @param error
30
26
  */
31
- export declare function checkError(error: ShowableError): void;
27
+ export declare function checkError(_error: ShowableError): void;
@@ -4,20 +4,24 @@
4
4
  *
5
5
  * Controls display & hiding of 4 days weather on Windy after startup
6
6
  *
7
- * @module startupWeather
8
- */
9
- import type { GeolocationInfo, HomeLocation } from '@windy/interfaces.d';
10
- export declare function removeListeners(): void;
11
- /**
12
- * Show the weather box on HP
7
+ * GUI on desktop works in two different modes:
8
+ *
9
+ * 1. Default mode - user has NO pinned favs on HP or has any, but do not want to see them permanently
10
+ *
11
+ * 2. Persistent mode (desktop only) - user has pinned favs on HP and wants to see them permanently
13
12
  *
14
- * @param coords At which location show the HP
13
+ * Both modes use completely different set of listeners that handle hide / show of HP weather
14
+ *
15
+ * @module startupWeather
15
16
  */
16
- export declare function show(coords: HomeLocation | GeolocationInfo, displayArticles?: boolean): void;
17
17
  /**
18
18
  * Hides, the weather DIV
19
19
  *
20
20
  * @param ev Event that initiated hiding
21
21
  */
22
- export declare function hide(ev?: MouseEvent | KeyboardEvent | TouchEvent): void;
22
+ export declare function hide(ev?: MouseEvent | KeyboardEvent | TouchEvent): Promise<void>;
23
+ /**
24
+ * Click on title or home button
25
+ */
26
+ export declare function back2home(): Promise<void>;
23
27
  export declare const getCancelShow: () => boolean;
@@ -71,7 +71,6 @@ declare class Store extends Evented<StoreTypes> {
71
71
  * @returns True if property exists
72
72
  */
73
73
  hasProperty: <T extends keyof DataSpecifications>(name: T) => boolean;
74
- _set<T extends keyof DataSpecifications, Item extends DataSpecifications[T]>(name: T, item: Item, opts: StoreOptions, value: Item['def'] | null): void;
75
74
  /**
76
75
  * Sets a value in key, value store. If succesfull,a nd value has been changed, store will brodcast message with name and value.
77
76
  * Limitation:** Our store is quite primitive so it can not compare Arrays and Objects. Always create new one or use `forceChange` * option.
@@ -137,6 +136,7 @@ declare class Store extends Evented<StoreTypes> {
137
136
  forceGet: boolean;
138
137
  }): Item['def'];
139
138
  isValid<T>(item: DataSpecificationsObject<T>, value: T): boolean;
139
+ private setFinally;
140
140
  }
141
141
  declare const store: Store;
142
142
  export declare const getAll: () => void, getAllowed: <T extends keyof DataSpecifications, Item extends DataSpecifications[T]>(name: T) => string | Item["allowed"], getDefault: <T extends keyof DataSpecifications, Item extends DataSpecifications[T]>(name: T) => Item["def"], get: <T extends keyof DataSpecifications, Item extends DataSpecifications[T]>(name: T, options?: {
@@ -144,5 +144,5 @@ export declare const getAll: () => void, getAllowed: <T extends keyof DataSpecif
144
144
  }) => Item["def"], on: <K extends keyof StoreTypes, Q extends StoreTypes[K]>(topic: K, callback: (...data: TrimUndefinedFromRight<Arrayify<Q>>) => void, context?: ThisType<unknown>, once?: boolean) => number, off: {
145
145
  (id: number): void;
146
146
  <K extends keyof StoreTypes, Q extends StoreTypes[K]>(topic: K, callback: (...data: TrimUndefinedFromRight<Arrayify<Q>>) => void, context?: ThisType<unknown>): void;
147
- }, once: <K extends keyof StoreTypes, Q extends StoreTypes[K]>(topic: K, callback: (...data: TrimUndefinedFromRight<Arrayify<Q>>) => void, context?: ThisType<unknown>) => number, set: <T extends keyof DataSpecifications, Item extends DataSpecifications[T]>(name: T, value: Item["def"], opts?: StoreOptions) => SetReturnType<T>;
147
+ }, once: <K extends keyof StoreTypes, Q extends StoreTypes[K]>(topic: K, callback: (...data: TrimUndefinedFromRight<Arrayify<Q>>) => void, context?: ThisType<unknown>) => number, set: <T extends keyof DataSpecifications, Item extends DataSpecifications[T]>(name: T, value: Item["def"], opts?: StoreOptions) => SetReturnType<T>, defineProperty: <T extends keyof DataSpecifications, Prop extends keyof DataSpecifications[T], Value extends DataSpecifications[T][Prop]>(name: T, prop: Prop, value: Value) => void, setDefault: <T extends keyof DataSpecifications, Item extends DataSpecifications[T]>(name: T, value: Item["def"]) => void;
148
148
  export default store;
@@ -0,0 +1,4 @@
1
+ /**
2
+ * Stores timezone offset for node-notif to know when to send notifications.
3
+ */
4
+ export declare const storeLastTimezoneOffset: () => void;
@@ -62,4 +62,5 @@ export declare const checkPendingSubscription: () => void;
62
62
  * It is used only as a gateway to solving the whole issue. It must be short and clear.
63
63
  */
64
64
  export declare const getBaitTitle: (issue: SubscriptionIssue | null) => string;
65
+ export declare const checkAndRenderSubsIssue: () => void;
65
66
  export {};
@@ -1,16 +1,16 @@
1
- import type { DownloadPayload, DownloadedInfo } from '../../plugins/offline/offline';
2
- export declare const cacheUrl: (cache: Cache, url: string, testIfUrlIsInCache?: boolean, tryTwice2DownloadFiles?: boolean) => Promise<boolean>;
1
+ import type { DownloadPayload, DownloadedInfo, FileInfo } from '../../types/offline';
2
+ export declare const cacheUrl: (cache: Cache, url: string, originalUrl: string, testIfUrlIsInCache?: boolean, tryTwice2DownloadFiles?: boolean) => Promise<boolean>;
3
3
  export declare const cancelOngoingDownloads: () => boolean;
4
4
  /**
5
5
  * Download all files in parallel
6
6
  * @param cache instance of Cache
7
7
  * @param urls list of rqrd URLs
8
- * @param checkIfUrlIsInCache Should we check if URKL is in cache before attempting to doqnload it?
9
- * @param calledOnDownlodedOneFile callback that is called each time one file is downloaded
10
- * @returns all Erorred urls or null if task was cenceled
8
+ * @param checkIfUrlIsInCache Should we check if URL is in cache before attempting to download it?
9
+ * @param calledOnDownloadedOneFile callback that is called each time one file is downloaded
10
+ * @returns all Errored urls or null if task was cancelled
11
11
  */
12
- export declare const downloadFilesInParallel: (cache: Cache, urls: string[], checkIfUrlIsInCache: boolean, tryTwice2DownloadFiles: boolean, calledOnDownlodedOneFile: () => void) => Promise<{
12
+ export declare const downloadFilesInParallel: (cache: Cache, urls: FileInfo[], checkIfUrlIsInCache: boolean, tryTwice2DownloadFiles: boolean, calledOnDownloadedOneFile: () => void) => Promise<{
13
13
  result: 'downloadingCanceled' | 'ok';
14
14
  errors?: string[];
15
15
  }>;
16
- export declare function download({ numberOfFiles, batches, mapBoundaries, overlays, products, daysToLoad, lastTimestamp, assets, mainEntryPoint, }: DownloadPayload): Promise<DownloadedInfo | void>;
16
+ export declare function download({ numberOfFiles, batches, assets, mainEntryPoint, }: DownloadPayload): Promise<DownloadedInfo | void>;
@@ -1,4 +1,4 @@
1
1
  export {};
2
2
  export declare const putInCache: (request: Request, response: Response) => Promise<void>;
3
3
  export declare const getFallbackResponse: () => Promise<Response>;
4
- export declare const cacheFirst: (request: Request, isConnectedToInternet: boolean) => Promise<Response>;
4
+ export declare const cacheFirst: (request: Request) => Promise<Response>;
@@ -1,7 +1,7 @@
1
1
  import type { Timestamp } from '@windy/types.d';
2
- import type { DownloadProgress, ServiceWorkerMessage } from '@plugins/offline/offline';
2
+ import type { DownloadProgress, ServiceWorkerMessage } from '../../types/offline';
3
3
  /**
4
- * The reson why we are using this function to wrap postMessage is that
4
+ * The reason why we are using this function to wrap postMessage is that
5
5
  * we can use TS to check typings of the message
6
6
  */
7
7
  export declare const sendMessageToClient: (message: ServiceWorkerMessage['data'] | DownloadProgress) => Promise<void>;
@@ -9,7 +9,7 @@ export declare const storeData: <T extends Object>(key: string, data: T) => Prom
9
9
  export declare const getData: <T extends Object>(key: string) => Promise<void | T>;
10
10
  export declare const deleteData: (key: string) => Promise<void>;
11
11
  /**
12
- * Soteres mainEntryPoint as /index.html so it will be always available on this URL
12
+ * Stores mainEntryPoint as /index.html so it will be always available on this URL
13
13
  * This is basically symlink in serviceWorker cache
14
14
  */
15
15
  export declare const storeMainEntryPoint: (mainEntryPoint: string) => Promise<void>;