@windycom/plugin-devtools 2.0.0 → 3.0.0
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.
- package/README.md +3 -0
- package/index.mjs +2 -2
- package/package.json +2 -3
- package/types/client/AccessProducts.d.ts +8 -0
- package/types/client/BottomSveltePlugins.d.ts +8 -0
- package/types/client/Calendar.d.ts +9 -17
- package/types/client/Color.d.ts +43 -90
- package/types/client/Evented.d.ts +4 -0
- package/types/client/ExternalSveltePlugin.d.ts +2 -1
- package/types/client/IDB.d.ts +63 -0
- package/types/client/IconProducts.d.ts +2 -0
- package/types/client/Layer.d.ts +1 -2
- package/types/client/Metric.d.ts +8 -8
- package/types/client/MetricClasses.d.ts +4 -3
- package/types/client/Overlay.d.ts +30 -15
- package/types/client/OverlayClasses.d.ts +11 -7
- package/types/client/Plugin.d.ts +2 -2
- package/types/client/Product.d.ts +40 -29
- package/types/client/RadarPlusProduct.d.ts +19 -0
- package/types/client/Renderer.d.ts +2 -10
- package/types/client/SveltePlugin.d.ts +9 -5
- package/types/client/TileLayer.d.ts +1 -2
- package/types/client/TopoMap.d.ts +10 -0
- package/types/client/WindowPlugin.d.ts +7 -3
- package/types/client/appsFlyer.d.ts +3 -0
- package/types/client/baseMap.d.ts +8 -5
- package/types/client/cityLabels.d.ts +10 -2
- package/types/client/cloudSync.d.ts +3 -1
- package/types/client/colorGradients.d.ts +13 -0
- package/types/client/customColors.d.ts +1 -0
- package/types/client/d.ts.files/Calendar.d.ts +11 -2
- package/types/client/d.ts.files/Color.d.ts +16 -5
- package/types/client/d.ts.files/LabelsLayer.d.ts +1 -18
- package/types/client/d.ts.files/Layer.d.ts +8 -1
- package/types/client/d.ts.files/Metric.d.ts +1 -0
- package/types/client/d.ts.files/Renderer.d.ts +22 -1
- package/types/client/d.ts.files/alerts.d.ts +120 -0
- package/types/client/d.ts.files/broadcast.d.ts +38 -10
- package/types/client/d.ts.files/dataSpecifications.d.ts +81 -122
- package/types/client/d.ts.files/favs.d.ts +69 -0
- package/types/client/d.ts.files/incomingMessages.d.ts +0 -4
- package/types/client/d.ts.files/notifications.d.ts +2 -2
- package/types/client/d.ts.files/plugin-params.d.ts +35 -47
- package/types/client/d.ts.files/plugins.d.ts +30 -42
- package/types/client/d.ts.files/pois.d.ts +1 -1
- package/types/client/d.ts.files/products.d.ts +15 -3
- package/types/client/d.ts.files/rootScope.d.ts +3 -21
- package/types/client/d.ts.files/startup.d.ts +59 -0
- package/types/client/d.ts.files/storage.d.ts +12 -35
- package/types/client/d.ts.files/user.d.ts +79 -24
- package/types/client/deviceLogging.d.ts +2 -1
- package/types/client/embed2.d.ts +14 -31
- package/types/client/fetch.d.ts +29 -16
- package/types/client/ga.d.ts +1 -1
- package/types/client/geolocation.d.ts +15 -7
- package/types/client/globals.d.ts +1 -0
- package/types/client/http.d.ts +17 -0
- package/types/client/idbInstances.d.ts +45 -0
- package/types/client/langFiles.d.ts +2 -0
- package/types/client/layers.d.ts +2 -0
- package/types/client/lib.d.ts +7 -21
- package/types/client/loadArticlesOrWhatsNew.d.ts +1 -0
- package/types/client/log.d.ts +1 -0
- package/types/client/lruCache.d.ts +6 -0
- package/types/client/map.d.ts +17 -6
- package/types/client/mobile.d.ts +28 -20
- package/types/client/models.d.ts +1 -1
- package/types/client/notifications.d.ts +32 -67
- package/types/client/overlays.d.ts +4 -1
- package/types/client/params.d.ts +0 -1
- package/types/client/permanentPromos.d.ts +1 -1
- package/types/client/persistentStorage.d.ts +8 -0
- package/types/client/picker.d.ts +1 -1
- package/types/client/pois.d.ts +1 -2
- package/types/client/promo.d.ts +6 -16
- package/types/client/pushNotifications.d.ts +13 -1
- package/types/client/queryString.d.ts +1 -1
- package/types/client/renderUtils.d.ts +1 -1
- package/types/client/renderers.d.ts +7 -3
- package/types/client/rootScope.d.ts +14 -23
- package/types/client/router.d.ts +9 -5
- package/types/client/seoParser.d.ts +21 -0
- package/types/client/serviceWorkerCtrl.d.ts +8 -0
- package/types/client/startupWeather.d.ts +13 -9
- package/types/client/store.d.ts +2 -2
- package/types/client/storeLastPosition.d.ts +1 -0
- package/types/client/subscription.d.ts +1 -0
- package/types/client/swDownloader.d.ts +7 -7
- package/types/client/swProxy.d.ts +1 -1
- package/types/client/swUtils.d.ts +3 -3
- package/types/client/trans.d.ts +26 -37
- package/types/client/user.d.ts +5 -13
- package/types/client/userAlerts.d.ts +68 -0
- package/types/client/userConsent.d.ts +6 -0
- package/types/client/userFavs.d.ts +46 -121
- package/types/client/utils.d.ts +28 -6
- package/types/iconfont.d.ts +1 -0
- package/types/interfaces.d.ts +90 -225
- package/types/lang-files.d.ts +687 -119
- package/types/offline.d.ts +100 -0
- package/types/types.d.ts +59 -24
- package/types/client/Bar.d.ts +0 -114
- package/types/client/BindedBar.d.ts +0 -51
- package/types/client/BindedCheckbox.d.ts +0 -30
- package/types/client/BindedSwitch.d.ts +0 -35
- package/types/client/BottomTagPlugin.d.ts +0 -8
- package/types/client/DraggableDiv.d.ts +0 -21
- package/types/client/GhostBox.d.ts +0 -17
- package/types/client/Legend.d.ts +0 -6
- package/types/client/LongTap.d.ts +0 -21
- package/types/client/MobileCalendar.d.ts +0 -51
- package/types/client/OfflineMessagesClasses.d.ts +0 -30
- package/types/client/ProductSwitch.d.ts +0 -14
- package/types/client/Scrollable.d.ts +0 -14
- package/types/client/Switch.d.ts +0 -24
- package/types/client/TimestampBar.d.ts +0 -8
- package/types/client/d.ts.files/Product.d.ts +0 -37
- package/types/client/d.ts.files/trans.d.ts +0 -55
- package/types/client/favs.d.ts +0 -83
- package/types/client/offlineController.d.ts +0 -20
|
@@ -12,16 +12,19 @@ import { DetailLocChangeParams } from '@plugins/detail/detail.d';
|
|
|
12
12
|
import { ParsLocation as GlobeParsLocation } from '@plugins/globe/main/receiver.d';
|
|
13
13
|
import { Params as GlobeParams, Poi as GlobePoi } from '@plugins/globe/types.d';
|
|
14
14
|
import { ExtendedDataAndParams } from '@plugins/isolines/IsolinesCanvas2D.d';
|
|
15
|
-
import { ClientMessage, DownloadProgress, ServiceWorkerMessage } from '@plugins/offline/offline';
|
|
16
15
|
import { Evented } from '@windy/Evented';
|
|
17
16
|
import { MetricIdent, MetricItem } from '@windy/Metric.d';
|
|
18
17
|
import { PluginIdent } from '@windy/Plugin';
|
|
19
18
|
import { NotificationPreferences } from '@windy/dataSpecifications.d';
|
|
20
|
-
import {
|
|
19
|
+
import { GeolocationInfo, LatLon, WeatherParameters } from '@windy/interfaces.d';
|
|
21
20
|
import { PluginSource, PluginsOpenParams, PluginsQsParams } from '@windy/plugin-params.d';
|
|
22
21
|
import { Plugins } from '@windy/plugins.d';
|
|
23
22
|
import { Pois } from '@windy/rootScope.d';
|
|
24
23
|
import type { ExternalPluginIdent } from '@windy/types';
|
|
24
|
+
import type { CenterOptions } from '@windy/map';
|
|
25
|
+
import type { AnimationOptions, FitBoundsOptions, LngLatBoundsLike } from '@windycom/maplibre-gl';
|
|
26
|
+
import type { ViewportBounds } from '@plugins/_shared/maplibre/utils/maplibreUtils';
|
|
27
|
+
import type { RadarPlusLayer } from '@plugins/radar-plus/types';
|
|
25
28
|
|
|
26
29
|
type BcastTypesNonGeneric = {
|
|
27
30
|
/**
|
|
@@ -74,9 +77,12 @@ export interface BasicBcastTypes<T extends keyof Plugins> {
|
|
|
74
77
|
/** Plugin was successfully loaded and closed */
|
|
75
78
|
pluginClosed: [PluginIdent | string];
|
|
76
79
|
|
|
77
|
-
/** Plugin was
|
|
80
|
+
/** Plugin was successfully closed */
|
|
78
81
|
pluginOpened: [PluginIdent | string];
|
|
79
82
|
|
|
83
|
+
/** Svelte plugin was successfully mounted */
|
|
84
|
+
pluginMounted: [PluginIdent | string];
|
|
85
|
+
|
|
80
86
|
/**
|
|
81
87
|
* Triggered when Windy has successfully loaded and rendered requested data.
|
|
82
88
|
* Use this for triggering your own tasks.
|
|
@@ -101,9 +107,12 @@ export interface BasicBcastTypes<T extends keyof Plugins> {
|
|
|
101
107
|
*/
|
|
102
108
|
metricChanged: [MetricIdent | undefined, MetricItem | undefined];
|
|
103
109
|
|
|
104
|
-
/** Indicates that user added, remover or rename his fav
|
|
110
|
+
/** Indicates that user added, remover or rename his fav */
|
|
105
111
|
favChanged: [];
|
|
106
112
|
|
|
113
|
+
/** Indicates that user added, remover or rename his alert */
|
|
114
|
+
alertChanged: [];
|
|
115
|
+
|
|
107
116
|
/**
|
|
108
117
|
* Indicates, that router has parsed URL and launched plugin
|
|
109
118
|
* that was requested in URL
|
|
@@ -114,15 +123,37 @@ export interface BasicBcastTypes<T extends keyof Plugins> {
|
|
|
114
123
|
/** @ignore */ globeOpened: [];
|
|
115
124
|
/** @ignore */ globeClose: [];
|
|
116
125
|
/** @ignore */ globeFailed: [];
|
|
126
|
+
|
|
117
127
|
/** @ignore */ 'globe-detail': [DetailLocChangeParams | (LatLon & PluginSource)];
|
|
118
128
|
/** @ignore */ 'globe-isolines': [ExtendedDataAndParams | null];
|
|
119
129
|
/** @ignore */ 'globe-poi': [GlobeParsLocation & { type?: string; id?: string }];
|
|
120
130
|
/** @ignore */ 'globe-zoomIn': [[number, number] | null] | [];
|
|
121
131
|
/** @ignore */ 'globe-zoomOut': [[number, number] | null] | [];
|
|
122
132
|
/** @ignore */ 'globe-paramsChanged': [GlobeParams];
|
|
123
|
-
|
|
124
|
-
/** @ignore */ '
|
|
125
|
-
/** @ignore */ '
|
|
133
|
+
|
|
134
|
+
/** @ignore */ 'leaflet-zoomIn': [number | undefined, L.ZoomOptions | undefined];
|
|
135
|
+
/** @ignore */ 'leaflet-zoomOut': [number | undefined, L.ZoomOptions | undefined];
|
|
136
|
+
/** @ignore */ 'leaflet-paramsChanged': [
|
|
137
|
+
WeatherParameters,
|
|
138
|
+
keyof WeatherParameters | undefined,
|
|
139
|
+
];
|
|
140
|
+
|
|
141
|
+
/** @ignore */ 'maplibre-zoomIn': [AnimationOptions | undefined, unknown | undefined];
|
|
142
|
+
/** @ignore */ 'maplibre-zoomOut': [AnimationOptions | undefined, unknown | undefined];
|
|
143
|
+
/** @ignore */ 'maplibre-setZoom': [number, unknown | undefined];
|
|
144
|
+
/** @ignore */ 'maplibre-centerMap': [CenterOptions];
|
|
145
|
+
/** @ignore */ 'maplibre-triggerDragging': [boolean];
|
|
146
|
+
/** @ignore */ 'maplibre-fitBounds': [LngLatBoundsLike, FitBoundsOptions | undefined];
|
|
147
|
+
/** @ignore */ 'maplibre-panToOffset': [number, number, number];
|
|
148
|
+
/** @ignore */ 'maplibre-ensurePointVisibleY': [number, number, number];
|
|
149
|
+
/** @ignore */ 'maplibre-moveEnd': [];
|
|
150
|
+
/** @ignore */ 'maplibre-zoomChange': [number];
|
|
151
|
+
/** @ignore */ 'maplibre-boundsChange': [ViewportBounds];
|
|
152
|
+
/** @ignore */ 'maplibre-paramsChanged': [
|
|
153
|
+
WeatherParameters,
|
|
154
|
+
keyof WeatherParameters | undefined,
|
|
155
|
+
];
|
|
156
|
+
/** @ignore */ 'radarPlus-open-layer': [RadarPlusLayer, boolean | undefined]; // Layer to open, whether to open layer for color editing
|
|
126
157
|
/** @ignore */ detailClose: [];
|
|
127
158
|
/** @ignore */ detailRendered: []; // used only in embed2
|
|
128
159
|
/** @ignore */ reloadFavs: [];
|
|
@@ -132,7 +163,6 @@ export interface BasicBcastTypes<T extends keyof Plugins> {
|
|
|
132
163
|
/** @ignore */ screenshotReady: [];
|
|
133
164
|
/** @ignore */ screenshotError: [Error];
|
|
134
165
|
/** @ignore */ onResume: [];
|
|
135
|
-
/** @ignore */ cloudSync: ['error', { data: Fav | string; action: string; type: 'fav' }];
|
|
136
166
|
/** @ignore */ back2home: [];
|
|
137
167
|
/** @ignore */ reloadMobileApp: [];
|
|
138
168
|
/** @ignore */ newLocation: [GeolocationInfo];
|
|
@@ -145,8 +175,6 @@ export interface BasicBcastTypes<T extends keyof Plugins> {
|
|
|
145
175
|
/** @ignore */ openCapAlerts: [PluginsOpenParams['picker']];
|
|
146
176
|
/** @ignore */ openapp: [];
|
|
147
177
|
/** @ignore */ openSearch: [];
|
|
148
|
-
/** @ignore */ offlineNativeMessage: [ClientMessage];
|
|
149
|
-
/** @ignore */ offlineClientMessage: [ServiceWorkerMessage | { data: DownloadProgress }];
|
|
150
178
|
}
|
|
151
179
|
|
|
152
180
|
interface BcastTypes<T extends keyof Plugins> extends BcastTypesNonGeneric, BasicBcastTypes<T> {}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import {
|
|
2
|
-
AcTimes,
|
|
3
2
|
GlobalPointProducts,
|
|
4
3
|
Isolines,
|
|
5
4
|
Levels,
|
|
@@ -26,17 +25,20 @@ import {
|
|
|
26
25
|
ShowableError,
|
|
27
26
|
SubTier,
|
|
28
27
|
Timestamp,
|
|
28
|
+
type Hours,
|
|
29
29
|
type RouteMotionSpeed,
|
|
30
|
+
type UsedMapLibrary,
|
|
31
|
+
type UserInterest,
|
|
30
32
|
} from '@windy/types.d';
|
|
31
33
|
|
|
32
|
-
import { ColorGradient } from '@windy/Color.d';
|
|
33
|
-
|
|
34
34
|
import { MetricItem } from '@windy/Metric.d';
|
|
35
35
|
|
|
36
|
+
import type { User, LoginAndFinishAction } from '@windy/user.d';
|
|
37
|
+
|
|
36
38
|
import type { SubscriptionInfo } from '@plugins/_shared/subscription-services/subscription-services.d';
|
|
37
|
-
import type { DownloadedInfo, OfflineConfiguration } from '@plugins/offline/offline.d';
|
|
38
39
|
import type RadarCalendar from '@plugins/radar/calendar/RadarCalendar';
|
|
39
40
|
import type SatelliteCalendar from '@plugins/satellite/calendar/SatelliteCalendar';
|
|
41
|
+
import type { NumberRange } from './alerts';
|
|
40
42
|
|
|
41
43
|
/**
|
|
42
44
|
* Custom animation particles settings
|
|
@@ -54,6 +56,9 @@ export interface CustomParticles {
|
|
|
54
56
|
*/
|
|
55
57
|
export interface NotificationPreferences {
|
|
56
58
|
email?: string;
|
|
59
|
+
preferredNotificationTime?: NumberRange[];
|
|
60
|
+
frequencyDays?: number;
|
|
61
|
+
usedTimezoneName?: string;
|
|
57
62
|
sendToEmail: boolean;
|
|
58
63
|
sendToMobile: boolean;
|
|
59
64
|
}
|
|
@@ -77,21 +82,6 @@ export interface Donation {
|
|
|
77
82
|
sub: string;
|
|
78
83
|
}
|
|
79
84
|
|
|
80
|
-
export interface User {
|
|
81
|
-
avatar?: string;
|
|
82
|
-
email?: string;
|
|
83
|
-
fullname?: string;
|
|
84
|
-
id: number;
|
|
85
|
-
username: string;
|
|
86
|
-
userslug: string;
|
|
87
|
-
verifiedEmail?: string;
|
|
88
|
-
|
|
89
|
-
/**
|
|
90
|
-
* Based on user location, cookie consent can be shown to the user if needed
|
|
91
|
-
*/
|
|
92
|
-
requiresCookieConsent?: boolean;
|
|
93
|
-
}
|
|
94
|
-
|
|
95
85
|
export interface MapCoordinates extends LatLon {
|
|
96
86
|
source: 'maps' | 'globe';
|
|
97
87
|
zoom: number;
|
|
@@ -150,12 +140,6 @@ export interface DataSpecificationsObject<T> {
|
|
|
150
140
|
*/
|
|
151
141
|
update?: Timestamp;
|
|
152
142
|
|
|
153
|
-
/**
|
|
154
|
-
* Allow overwrite start-up URL
|
|
155
|
-
* TODO: Refactor. Used only once in router.ts
|
|
156
|
-
*/
|
|
157
|
-
allowUrlRewrite?: boolean;
|
|
158
|
-
|
|
159
143
|
/**
|
|
160
144
|
* Setter function (will be run before value is set)
|
|
161
145
|
*/
|
|
@@ -176,7 +160,6 @@ export interface DataSpecificationsObject<T> {
|
|
|
176
160
|
* `overlay`,
|
|
177
161
|
* `level`,
|
|
178
162
|
* `availLevels`,
|
|
179
|
-
* `acTime`,
|
|
180
163
|
* `timestamp`,
|
|
181
164
|
* `isolines`,
|
|
182
165
|
* `product`,
|
|
@@ -206,9 +189,9 @@ export interface DataSpecifications {
|
|
|
206
189
|
level: DataSpecificationsObject<Levels>;
|
|
207
190
|
|
|
208
191
|
/**
|
|
209
|
-
* Rain/snow
|
|
192
|
+
* Rain/snow/wind accumulations time range in hours
|
|
210
193
|
*/
|
|
211
|
-
|
|
194
|
+
acRange: DataSpecificationsObject<Hours>;
|
|
212
195
|
|
|
213
196
|
/**
|
|
214
197
|
* Timestamp of actual weather moment. Use freely and without hesitation. Must be valid timestamp in ms, that is
|
|
@@ -229,9 +212,14 @@ export interface DataSpecifications {
|
|
|
229
212
|
path: DataSpecificationsObject<Path>;
|
|
230
213
|
|
|
231
214
|
/**
|
|
232
|
-
*
|
|
215
|
+
* Which type of isolines to render
|
|
233
216
|
*/
|
|
234
|
-
|
|
217
|
+
isolinesType: DataSpecificationsObject<Isolines>;
|
|
218
|
+
|
|
219
|
+
/**
|
|
220
|
+
* Whether to render isolines
|
|
221
|
+
*/
|
|
222
|
+
isolinesOn: DataSpecificationsObject<boolean>;
|
|
235
223
|
|
|
236
224
|
/**
|
|
237
225
|
* Product is set of weather data, that have same resolution, boundaries, time range and so on.
|
|
@@ -250,11 +238,6 @@ export interface DataSpecifications {
|
|
|
250
238
|
*/
|
|
251
239
|
visibleProducts: DataSpecificationsObject<Products[]>;
|
|
252
240
|
|
|
253
|
-
/**
|
|
254
|
-
* Available accumulation times for give overlay and product combination
|
|
255
|
-
*/
|
|
256
|
-
availAcTimes: DataSpecificationsObject<AcTimes[]>;
|
|
257
|
-
|
|
258
241
|
/**
|
|
259
242
|
* Global fallback product that handles situation
|
|
260
243
|
* when user pans the map out of bounds of local
|
|
@@ -330,15 +313,22 @@ export interface DataSpecifications {
|
|
|
330
313
|
isImperial: DataSpecificationsObject<boolean>;
|
|
331
314
|
|
|
332
315
|
/**
|
|
333
|
-
* Type of map shown in detail
|
|
316
|
+
* Type of map tiles map shown in detail
|
|
334
317
|
*/
|
|
335
318
|
map: DataSpecificationsObject<'sznmap' | 'sat' | 'winter'>;
|
|
336
319
|
|
|
320
|
+
/**
|
|
321
|
+
* Which type of map library is used
|
|
322
|
+
*/
|
|
323
|
+
mapLibrary: DataSpecificationsObject<UsedMapLibrary>;
|
|
324
|
+
|
|
337
325
|
/**
|
|
338
326
|
* Show 7 days weather on startup
|
|
339
327
|
*/
|
|
340
328
|
showWeather: DataSpecificationsObject<boolean>;
|
|
341
329
|
|
|
330
|
+
stormSettingsLightning: DataSpecificationsObject<boolean>;
|
|
331
|
+
|
|
342
332
|
/**
|
|
343
333
|
* Is WebGL disabled?
|
|
344
334
|
*/
|
|
@@ -354,6 +344,11 @@ export interface DataSpecifications {
|
|
|
354
344
|
*/
|
|
355
345
|
usedLang: DataSpecificationsObject<SupportedLanguages>;
|
|
356
346
|
|
|
347
|
+
/**
|
|
348
|
+
* The difference in minutes between UTC and the local time on the device.
|
|
349
|
+
*/
|
|
350
|
+
lastTimezoneOffset: DataSpecificationsObject<number>;
|
|
351
|
+
|
|
357
352
|
/**
|
|
358
353
|
* Particles animation settings
|
|
359
354
|
*/
|
|
@@ -411,11 +406,6 @@ export interface DataSpecifications {
|
|
|
411
406
|
*/
|
|
412
407
|
startupReverseName: DataSpecificationsObject<ReverseResult | null>;
|
|
413
408
|
|
|
414
|
-
/**
|
|
415
|
-
* NOTAMs marked as read
|
|
416
|
-
*/
|
|
417
|
-
notams: DataSpecificationsObject<Record<string, number> | null>;
|
|
418
|
-
|
|
419
409
|
/**
|
|
420
410
|
* Users email
|
|
421
411
|
*/
|
|
@@ -431,6 +421,11 @@ export interface DataSpecifications {
|
|
|
431
421
|
*/
|
|
432
422
|
displayHeliports: DataSpecificationsObject<boolean>;
|
|
433
423
|
|
|
424
|
+
/**
|
|
425
|
+
* Display Airspaces map layer in the METARs POI layer
|
|
426
|
+
*/
|
|
427
|
+
displayAirspaces: DataSpecificationsObject<boolean>;
|
|
428
|
+
|
|
434
429
|
/**
|
|
435
430
|
* User statistics
|
|
436
431
|
* @ignore
|
|
@@ -449,17 +444,11 @@ export interface DataSpecifications {
|
|
|
449
444
|
*/
|
|
450
445
|
seenRadarInfo: DataSpecificationsObject<boolean>;
|
|
451
446
|
|
|
452
|
-
/**
|
|
453
|
-
* Wheather picker was dragged or not (not settings but info)
|
|
454
|
-
* @ignore
|
|
455
|
-
*/
|
|
456
|
-
wasDragged: DataSpecificationsObject<boolean>;
|
|
457
|
-
|
|
458
447
|
/**
|
|
459
448
|
* Detail's location - TODO: get rid of async name property
|
|
460
449
|
* @ignore
|
|
461
450
|
*/
|
|
462
|
-
detailLocation: DataSpecificationsObject<(LatLon & { name?: string }) | null>;
|
|
451
|
+
detailLocation: DataSpecificationsObject<(LatLon & { name?: string; id?: string }) | null>;
|
|
463
452
|
|
|
464
453
|
/**
|
|
465
454
|
* 1h step of forecast
|
|
@@ -495,31 +484,16 @@ export interface DataSpecifications {
|
|
|
495
484
|
*/
|
|
496
485
|
capDisplay: DataSpecificationsObject<'all' | 'today' | 'tomm' | 'later'>;
|
|
497
486
|
|
|
498
|
-
/**
|
|
499
|
-
* Range of displayed radar history
|
|
500
|
-
*/
|
|
501
|
-
radarRange: DataSpecificationsObject<'archive' | 'long' | 'medium' | 'short'>;
|
|
502
|
-
|
|
503
487
|
/**
|
|
504
488
|
* Timestamp in ms
|
|
505
489
|
*/
|
|
506
490
|
radarTimestamp: DataSpecificationsObject<Timestamp>;
|
|
507
491
|
|
|
508
|
-
/**
|
|
509
|
-
* Animation speed
|
|
510
|
-
*/
|
|
511
|
-
radarSpeed: DataSpecificationsObject<'slow' | 'medium' | 'fast'>;
|
|
512
|
-
|
|
513
492
|
/**
|
|
514
493
|
* Radar calendar
|
|
515
494
|
*/
|
|
516
495
|
radarCalendar: DataSpecificationsObject<RadarCalendar | null>;
|
|
517
496
|
|
|
518
|
-
/**
|
|
519
|
-
* Animation is running
|
|
520
|
-
*/
|
|
521
|
-
radarAnimation: DataSpecificationsObject<boolean>;
|
|
522
|
-
|
|
523
497
|
/**
|
|
524
498
|
* Visible lightning data on radar
|
|
525
499
|
*/
|
|
@@ -530,11 +504,6 @@ export interface DataSpecifications {
|
|
|
530
504
|
*/
|
|
531
505
|
blitzSoundOn: DataSpecificationsObject<boolean>;
|
|
532
506
|
|
|
533
|
-
/**
|
|
534
|
-
* Range of displayed satellite history
|
|
535
|
-
*/
|
|
536
|
-
satelliteRange: DataSpecificationsObject<'archive' | 'long' | 'medium' | 'short'>;
|
|
537
|
-
|
|
538
507
|
/**
|
|
539
508
|
* Timestamp in ms
|
|
540
509
|
*/
|
|
@@ -546,19 +515,9 @@ export interface DataSpecifications {
|
|
|
546
515
|
satelliteCalendar: DataSpecificationsObject<SatelliteCalendar | null>;
|
|
547
516
|
|
|
548
517
|
/**
|
|
549
|
-
*
|
|
550
|
-
*/
|
|
551
|
-
satelliteAnimation: DataSpecificationsObject<boolean>;
|
|
552
|
-
|
|
553
|
-
/**
|
|
554
|
-
* Satellite visualization modes
|
|
518
|
+
* Interpolate images using vectors
|
|
555
519
|
*/
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
/**
|
|
559
|
-
* Animation speed
|
|
560
|
-
*/
|
|
561
|
-
satelliteSpeed: DataSpecificationsObject<'slow' | 'medium' | 'fast'>;
|
|
520
|
+
radSatFlowOn: DataSpecificationsObject<boolean>;
|
|
562
521
|
|
|
563
522
|
/**
|
|
564
523
|
* Extrapolate satellite images to future
|
|
@@ -687,14 +646,6 @@ export interface DataSpecifications {
|
|
|
687
646
|
*/
|
|
688
647
|
notifications: DataSpecificationsObject<NotificationPreferences | null>;
|
|
689
648
|
|
|
690
|
-
/**
|
|
691
|
-
* User likes to receive ad hoc pushNotification
|
|
692
|
-
* For instance METAR update.
|
|
693
|
-
* Once set, it always stays on on this device
|
|
694
|
-
* @ignore
|
|
695
|
-
*/
|
|
696
|
-
adHocNotification: DataSpecificationsObject<boolean>;
|
|
697
|
-
|
|
698
649
|
/**
|
|
699
650
|
* Number of unread notifications
|
|
700
651
|
* @ignore
|
|
@@ -729,11 +680,6 @@ export interface DataSpecifications {
|
|
|
729
680
|
*/
|
|
730
681
|
authHash: DataSpecificationsObject<string | null>;
|
|
731
682
|
|
|
732
|
-
/**
|
|
733
|
-
* Globe plugin is active (used for disabling isolines in overlays plugin)
|
|
734
|
-
*/
|
|
735
|
-
globeActive: DataSpecificationsObject<boolean>;
|
|
736
|
-
|
|
737
683
|
/**
|
|
738
684
|
* Webcam or station last location (used for globe picker initial location)
|
|
739
685
|
* @ignore
|
|
@@ -757,12 +703,6 @@ export interface DataSpecifications {
|
|
|
757
703
|
*/
|
|
758
704
|
launchedBy: DataSpecificationsObject<'radar-widget' | null>;
|
|
759
705
|
|
|
760
|
-
/**
|
|
761
|
-
* Any stored color
|
|
762
|
-
* @ignore
|
|
763
|
-
*/
|
|
764
|
-
[key: `color2_${string}`]: DataSpecificationsObject<ColorGradient | null>;
|
|
765
|
-
|
|
766
706
|
/**
|
|
767
707
|
* Any stored metric
|
|
768
708
|
* @ignore
|
|
@@ -836,35 +776,15 @@ export interface DataSpecifications {
|
|
|
836
776
|
*/
|
|
837
777
|
pickerMobileTimeout: DataSpecificationsObject<PickerMobileTimeout>;
|
|
838
778
|
|
|
839
|
-
/**
|
|
840
|
-
* Selected area and layers for offline mode
|
|
841
|
-
* @ignore
|
|
842
|
-
*/
|
|
843
|
-
offlineSetting: DataSpecificationsObject<OfflineConfiguration | null>;
|
|
844
|
-
|
|
845
779
|
/**
|
|
846
780
|
* Endable/dissable change of detail location, when map is dragged
|
|
847
781
|
*/
|
|
848
782
|
changeDetailOnMapDrag: DataSpecificationsObject<boolean>;
|
|
849
783
|
|
|
850
784
|
/**
|
|
851
|
-
*
|
|
852
|
-
* @ignore
|
|
853
|
-
*/
|
|
854
|
-
offlineMode: DataSpecificationsObject<boolean>;
|
|
855
|
-
|
|
856
|
-
/**
|
|
857
|
-
* Imfo about offline data residing in serviceWorker
|
|
858
|
-
* @ignore
|
|
859
|
-
*/
|
|
860
|
-
offlineDataInfo: DataSpecificationsObject<DownloadedInfo | null>;
|
|
861
|
-
|
|
862
|
-
/**
|
|
863
|
-
* Enables/disables offline mode at all. If false, offline mode is not available
|
|
864
|
-
* and serviceWorker is not installed at all
|
|
865
|
-
* @ignore
|
|
785
|
+
* Timestamp in ms
|
|
866
786
|
*/
|
|
867
|
-
|
|
787
|
+
radsatTimestamp: DataSpecificationsObject<Timestamp>;
|
|
868
788
|
|
|
869
789
|
/**
|
|
870
790
|
* Display this type of WX stations on POI map
|
|
@@ -888,11 +808,17 @@ export interface DataSpecifications {
|
|
|
888
808
|
stationCompareHiddenProducts: DataSpecificationsObject<PointProducts[]>;
|
|
889
809
|
|
|
890
810
|
/**
|
|
891
|
-
* Main
|
|
811
|
+
* Main GDPR, privacy or cookie consent object
|
|
892
812
|
* @ignore
|
|
893
813
|
*/
|
|
894
814
|
consent: DataSpecificationsObject<Consent | null>;
|
|
895
815
|
|
|
816
|
+
/**
|
|
817
|
+
* Is analytics consent required
|
|
818
|
+
* @ignore
|
|
819
|
+
*/
|
|
820
|
+
analyticsConsentRequired: DataSpecificationsObject<boolean | null>;
|
|
821
|
+
|
|
896
822
|
/**
|
|
897
823
|
* Youtube cookie consent object
|
|
898
824
|
* @ignore
|
|
@@ -920,6 +846,39 @@ export interface DataSpecifications {
|
|
|
920
846
|
* User has entered into arrange mode in RH menu
|
|
921
847
|
*/
|
|
922
848
|
rhMenuArrangeMode: DataSpecificationsObject<boolean>;
|
|
849
|
+
|
|
850
|
+
/*
|
|
851
|
+
* If startup widgets should persist
|
|
852
|
+
*/
|
|
853
|
+
persistentWidgets: DataSpecificationsObject<boolean>;
|
|
854
|
+
|
|
855
|
+
/**
|
|
856
|
+
* List of interests user has, based on onboarding picker
|
|
857
|
+
*/
|
|
858
|
+
userInterests: DataSpecificationsObject<UserInterest[]>;
|
|
859
|
+
|
|
860
|
+
onboardingFinished: DataSpecificationsObject<boolean>;
|
|
861
|
+
|
|
862
|
+
locationPermissionsGranted: DataSpecificationsObject<boolean>;
|
|
863
|
+
|
|
864
|
+
doNotShowLocationPermissionsPopup: DataSpecificationsObject<boolean>;
|
|
865
|
+
|
|
866
|
+
locationPermissionsPopupShown: DataSpecificationsObject<number | null>;
|
|
867
|
+
|
|
868
|
+
loginAndFinishAction: DataSpecificationsObject<
|
|
869
|
+
(LoginAndFinishAction & { updated: Timestamp }) | null
|
|
870
|
+
>;
|
|
871
|
+
|
|
872
|
+
/**
|
|
873
|
+
* If user wants to display just some type of favs in favs plugin
|
|
874
|
+
*/
|
|
875
|
+
favsFilter: DataSpecificationsObject<FavTypeNew[]>;
|
|
876
|
+
|
|
877
|
+
/**
|
|
878
|
+
* Contains information, that registration hash for pushNotifications has been
|
|
879
|
+
* successfully sent to the backend
|
|
880
|
+
*/
|
|
881
|
+
pushNotificationsReady: DataSpecificationsObject<boolean>;
|
|
923
882
|
}
|
|
924
883
|
|
|
925
884
|
/**
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
import type { RouteType, StationId, Timestamp } from '@windy/types';
|
|
2
|
+
import type { LatLon, Alert, AlertProps } from '@windy/interfaces';
|
|
3
|
+
|
|
4
|
+
export type FavId = string;
|
|
5
|
+
|
|
6
|
+
/** New fav type not including alerts */
|
|
7
|
+
export type FavTypeNew = 'fav' | 'airport' | 'station' | 'webcam' | 'route';
|
|
8
|
+
|
|
9
|
+
/** @deprecated Old fav type including alert that will be abandoned soon */
|
|
10
|
+
export type FavType = FavTypeNew | 'alert';
|
|
11
|
+
|
|
12
|
+
export type RouteAsString = `${RouteType}/${string}`;
|
|
13
|
+
|
|
14
|
+
export type FavFragment =
|
|
15
|
+
| (LatLon & {
|
|
16
|
+
/** Title of the fav */
|
|
17
|
+
title: string;
|
|
18
|
+
}) &
|
|
19
|
+
(
|
|
20
|
+
| { type: 'fav' }
|
|
21
|
+
|
|
22
|
+
/** @deprecated use till migration of alerts is in process */
|
|
23
|
+
| {
|
|
24
|
+
type: 'alert';
|
|
25
|
+
alert: Alert;
|
|
26
|
+
alertProps: AlertProps;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
/** Airport ICAO code in case of airport */
|
|
30
|
+
| { type: 'airport'; icao: string }
|
|
31
|
+
|
|
32
|
+
/** Weather station ID (if WX station) */
|
|
33
|
+
| { type: 'station'; stationId: StationId }
|
|
34
|
+
| { type: 'webcam'; webcamId: number }
|
|
35
|
+
| { type: 'route'; route: RouteAsString }
|
|
36
|
+
);
|
|
37
|
+
|
|
38
|
+
export type Fav = FavFragment & {
|
|
39
|
+
/** Unique mongoDb ID of item */
|
|
40
|
+
id: FavId;
|
|
41
|
+
|
|
42
|
+
/**
|
|
43
|
+
* If user wants to pin to top this fav, this timestamp enable us to sort all the favs
|
|
44
|
+
* so the last pinned is on top
|
|
45
|
+
*/
|
|
46
|
+
pin2top?: Timestamp | null;
|
|
47
|
+
|
|
48
|
+
/**
|
|
49
|
+
* If user wants to pin to homepage this fav, this timestamp enable us to sort all the favs
|
|
50
|
+
* so the last pinned is first in line
|
|
51
|
+
*/
|
|
52
|
+
pin2homepage?: Timestamp | null;
|
|
53
|
+
|
|
54
|
+
/**
|
|
55
|
+
* Timestamp when the item has been updated for the last time. It is used for updating items on all devices (the most up-to-date wins)
|
|
56
|
+
*/
|
|
57
|
+
updated: Timestamp;
|
|
58
|
+
};
|
|
59
|
+
|
|
60
|
+
export type ObsoleteFav = FavFragment & {
|
|
61
|
+
key: string;
|
|
62
|
+
};
|
|
63
|
+
|
|
64
|
+
export type FavQuery =
|
|
65
|
+
| { webcamsId: number }
|
|
66
|
+
| { stationId: StationId }
|
|
67
|
+
| { icao: string }
|
|
68
|
+
| { type: FavType }
|
|
69
|
+
| { title: string };
|
|
@@ -53,10 +53,6 @@ export interface QueryStringEmbedParams {
|
|
|
53
53
|
product?: Products;
|
|
54
54
|
showDetail: boolean;
|
|
55
55
|
showMarker: boolean;
|
|
56
|
-
/**
|
|
57
|
-
* @deprecated Only used for query string of type=alert
|
|
58
|
-
*/
|
|
59
|
-
timestamps?: string;
|
|
60
56
|
type: 'map' | 'alert' | 'forecast';
|
|
61
57
|
zoom: number;
|
|
62
58
|
}
|