@windycom/plugin-devtools 3.0.1 → 3.0.2
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 +1 -0
- package/package.json +1 -1
- package/types/client/Calendar.d.ts +101 -71
- package/types/client/Color.d.ts +18 -5
- package/types/client/DataTiler.d.ts +1 -1
- package/types/client/EcmwfProduct.d.ts +22 -0
- package/types/client/IDB.d.ts +1 -1
- package/types/client/Layer.d.ts +95 -26
- package/types/client/LayerClasses.d.ts +5 -0
- package/types/client/Metric.d.ts +31 -46
- package/types/client/Overlay.d.ts +8 -11
- package/types/client/OverlayClasses.d.ts +8 -0
- package/types/client/Particles.d.ts +1 -1
- package/types/client/Product.d.ts +31 -65
- package/types/client/ProductClasses.d.ts +44 -0
- package/types/client/RadarPlusProduct.d.ts +1 -1
- package/types/client/Renderer.d.ts +41 -13
- package/types/client/SatelliteProduct.d.ts +1 -1
- package/types/client/SveltePlugin.d.ts +1 -1
- package/types/client/TileLayer.d.ts +2 -2
- package/types/client/TopoMap.d.ts +2 -3
- package/types/client/WindowPlugin.d.ts +6 -3
- package/types/client/appsFlyer.d.ts +2 -1
- package/types/client/colorGradients.d.ts +5 -10
- package/types/client/colors.d.ts +1 -2
- package/types/client/d.ts.files/Metric.d.ts +21 -2
- package/types/client/d.ts.files/TileLayerCanvas.d.ts +3 -3
- package/types/client/d.ts.files/alerts.d.ts +1 -0
- package/types/client/d.ts.files/broadcast.d.ts +3 -3
- package/types/client/d.ts.files/dataSpecifications.d.ts +32 -34
- package/types/client/d.ts.files/favs.d.ts +7 -18
- package/types/client/d.ts.files/http.d.ts +5 -0
- package/types/client/d.ts.files/lib.d.ts +0 -1
- package/types/client/d.ts.files/plugin-params.d.ts +20 -16
- package/types/client/d.ts.files/plugins.d.ts +0 -2
- package/types/client/d.ts.files/rootScope.d.ts +2 -0
- package/types/client/d.ts.files/webcams.d.ts +9 -2
- package/types/client/dataLoader.d.ts +2 -2
- package/types/client/detectDevice.d.ts +3 -0
- package/types/client/embed.d.ts +0 -2
- package/types/client/errorLogger.d.ts +1 -1
- package/types/client/externalPlugins.d.ts +2 -0
- package/types/client/fetch.d.ts +28 -4
- package/types/client/format.d.ts +1 -0
- package/types/client/glTileRender.d.ts +1 -7
- package/types/client/idbInstances.d.ts +115 -4
- package/types/client/layers.d.ts +3 -1
- package/types/client/legends.d.ts +1 -1
- package/types/client/lib.d.ts +0 -7
- package/types/client/map.d.ts +7 -1
- package/types/client/mobile.d.ts +0 -7
- package/types/client/models.d.ts +2 -6
- package/types/client/overlays.d.ts +2 -1
- package/types/client/particleRenderers.d.ts +1 -1
- package/types/client/plugins.d.ts +0 -4
- package/types/client/products.d.ts +54 -2
- package/types/client/promo.d.ts +28 -5
- package/types/client/pushNotifications.d.ts +19 -1
- package/types/client/renderCtrl.d.ts +1 -1
- package/types/client/renderTile.d.ts +2 -2
- package/types/client/renderUtils.d.ts +16 -36
- package/types/client/renderers.d.ts +2 -4
- package/types/client/reverseName.d.ts +2 -1
- package/types/client/rhMessage.d.ts +1 -1
- package/types/client/rootScope.d.ts +14 -6
- package/types/client/router.d.ts +36 -9
- package/types/client/seoParser.d.ts +35 -0
- package/types/client/showableErrorsService.d.ts +10 -6
- package/types/client/store.d.ts +20 -52
- package/types/client/tileInterpolator.d.ts +1 -1
- package/types/client/userAlerts.d.ts +0 -4
- package/types/client/userFavs.d.ts +23 -10
- package/types/client/utils.d.ts +18 -17
- package/types/interfaces.d.ts +197 -16
- package/types/lang-files.d.ts +167 -27
- package/types/types.d.ts +297 -7
- package/types/client/d.ts.files/Calendar.d.ts +0 -96
- package/types/client/d.ts.files/Color.d.ts +0 -94
- package/types/client/d.ts.files/Layer.d.ts +0 -191
- package/types/client/d.ts.files/Renderer.d.ts +0 -44
- package/types/client/d.ts.files/products.d.ts +0 -60
- package/types/client/imaker.d.ts +0 -112
- package/types/offline.d.ts +0 -100
|
@@ -20,7 +20,6 @@ import {
|
|
|
20
20
|
|
|
21
21
|
import {
|
|
22
22
|
MenuItems,
|
|
23
|
-
Path,
|
|
24
23
|
PickerMobileTimeout,
|
|
25
24
|
ShowableError,
|
|
26
25
|
SubTier,
|
|
@@ -29,6 +28,7 @@ import {
|
|
|
29
28
|
RouteMotionSpeed,
|
|
30
29
|
UsedMapLibrary,
|
|
31
30
|
UserInterest,
|
|
31
|
+
type ISOCountryCode,
|
|
32
32
|
} from '@windy/types.d';
|
|
33
33
|
|
|
34
34
|
import { MetricItem } from '@windy/Metric.d';
|
|
@@ -39,7 +39,8 @@ import type { SubscriptionInfo } from '@plugins/_shared/subscription-services/su
|
|
|
39
39
|
import type RadarCalendar from '@plugins/radar/calendar/RadarCalendar';
|
|
40
40
|
import type SatelliteCalendar from '@plugins/satellite/calendar/SatelliteCalendar';
|
|
41
41
|
import type { NumberRange } from '@windy/alerts.d';
|
|
42
|
-
import type {
|
|
42
|
+
import type { FavType } from '@windy/favs.d';
|
|
43
|
+
import type RadarPlusCalendar from '@plugins/radar-plus/calendar/radarPlusCalendar';
|
|
43
44
|
|
|
44
45
|
/**
|
|
45
46
|
* Custom animation particles settings
|
|
@@ -73,6 +74,7 @@ export interface ReverseResult extends LatLon {
|
|
|
73
74
|
lang: string;
|
|
74
75
|
region?: string;
|
|
75
76
|
country?: string;
|
|
77
|
+
cc?: ISOCountryCode;
|
|
76
78
|
name: string;
|
|
77
79
|
nameValid?: boolean;
|
|
78
80
|
}
|
|
@@ -103,7 +105,7 @@ export interface DataSpecificationsObject<T> {
|
|
|
103
105
|
allowed: Readonly<T[]> | ((d: T) => boolean);
|
|
104
106
|
|
|
105
107
|
/**
|
|
106
|
-
*
|
|
108
|
+
* Persistent item. Save this item to localStorage
|
|
107
109
|
*/
|
|
108
110
|
save?: boolean;
|
|
109
111
|
|
|
@@ -150,6 +152,12 @@ export interface DataSpecificationsObject<T> {
|
|
|
150
152
|
* Setter function - asynchronous (will be run before value is set)
|
|
151
153
|
*/
|
|
152
154
|
asyncSet?: (...args: unknown[]) => Promise<T>;
|
|
155
|
+
|
|
156
|
+
/**
|
|
157
|
+
* This item can be set only by syncSet or asyncSet (so basically it is derived store)
|
|
158
|
+
* This so far does not do anything, it's merely a flag for developer
|
|
159
|
+
*/
|
|
160
|
+
readOnly?: boolean;
|
|
153
161
|
}
|
|
154
162
|
|
|
155
163
|
export interface FeatureFlags {
|
|
@@ -211,12 +219,6 @@ export interface DataSpecifications {
|
|
|
211
219
|
*/
|
|
212
220
|
timestamp: DataSpecificationsObject<Timestamp>;
|
|
213
221
|
|
|
214
|
-
/**
|
|
215
|
-
* Read only value! UTC string containing time of actually rendered data that are available for current overlay and weather model.
|
|
216
|
-
* @ignore
|
|
217
|
-
*/
|
|
218
|
-
path: DataSpecificationsObject<Path | null>;
|
|
219
|
-
|
|
220
222
|
/**
|
|
221
223
|
* Which type of isolines to render
|
|
222
224
|
*/
|
|
@@ -272,11 +274,6 @@ export interface DataSpecifications {
|
|
|
272
274
|
*/
|
|
273
275
|
particlesAnim: DataSpecificationsObject<'on' | 'off' | 'intensive'>;
|
|
274
276
|
|
|
275
|
-
/**
|
|
276
|
-
* Last modified timestamp of just rendered data (read only)
|
|
277
|
-
*/
|
|
278
|
-
lastModified: DataSpecificationsObject<Timestamp>;
|
|
279
|
-
|
|
280
277
|
/**
|
|
281
278
|
* Display graticule over the map
|
|
282
279
|
*/
|
|
@@ -345,16 +342,6 @@ export interface DataSpecifications {
|
|
|
345
342
|
|
|
346
343
|
stormSettingsLightning: DataSpecificationsObject<boolean>;
|
|
347
344
|
|
|
348
|
-
/**
|
|
349
|
-
* Is WebGL disabled?
|
|
350
|
-
*/
|
|
351
|
-
disableWebGL: DataSpecificationsObject<boolean>;
|
|
352
|
-
|
|
353
|
-
/**
|
|
354
|
-
* Indicates whether glParticles are on or off
|
|
355
|
-
*/
|
|
356
|
-
glParticlesOn: DataSpecificationsObject<boolean>;
|
|
357
|
-
|
|
358
345
|
/**
|
|
359
346
|
* Finally used language (the one which is successfully loaded in trans module)
|
|
360
347
|
*/
|
|
@@ -496,12 +483,8 @@ export interface DataSpecifications {
|
|
|
496
483
|
*/
|
|
497
484
|
camsPreviews: DataSpecificationsObject<boolean>;
|
|
498
485
|
|
|
499
|
-
//
|
|
500
|
-
// CAP alerts
|
|
501
|
-
//
|
|
502
|
-
|
|
503
486
|
/**
|
|
504
|
-
* Today,
|
|
487
|
+
* Today, tomorrow, later
|
|
505
488
|
*/
|
|
506
489
|
capDisplay: DataSpecificationsObject<'all' | 'today' | 'tomm' | 'later'>;
|
|
507
490
|
|
|
@@ -624,7 +607,7 @@ export interface DataSpecifications {
|
|
|
624
607
|
zuluMode: DataSpecificationsObject<boolean>;
|
|
625
608
|
|
|
626
609
|
/**
|
|
627
|
-
* Sorting of nearest
|
|
610
|
+
* Sorting of nearest weather stations
|
|
628
611
|
* @ignore
|
|
629
612
|
*/
|
|
630
613
|
stationsSort: DataSpecificationsObject<'profi' | 'distance'>;
|
|
@@ -792,7 +775,7 @@ export interface DataSpecifications {
|
|
|
792
775
|
pickerMobileTimeout: DataSpecificationsObject<PickerMobileTimeout>;
|
|
793
776
|
|
|
794
777
|
/**
|
|
795
|
-
*
|
|
778
|
+
* Enable/disable change of detail location, when map is dragged
|
|
796
779
|
*/
|
|
797
780
|
changeDetailOnMapDrag: DataSpecificationsObject<boolean>;
|
|
798
781
|
|
|
@@ -801,6 +784,11 @@ export interface DataSpecifications {
|
|
|
801
784
|
*/
|
|
802
785
|
radsatTimestamp: DataSpecificationsObject<Timestamp>;
|
|
803
786
|
|
|
787
|
+
/**
|
|
788
|
+
* RadarPlus calendar
|
|
789
|
+
*/
|
|
790
|
+
radarPlusCalendar: DataSpecificationsObject<RadarPlusCalendar | null>;
|
|
791
|
+
|
|
804
792
|
/**
|
|
805
793
|
* Display this type of WX stations on POI map
|
|
806
794
|
* @ignore
|
|
@@ -881,7 +869,7 @@ export interface DataSpecifications {
|
|
|
881
869
|
/**
|
|
882
870
|
* If user wants to display just some type of favs in favs plugin
|
|
883
871
|
*/
|
|
884
|
-
favsFilter: DataSpecificationsObject<
|
|
872
|
+
favsFilter: DataSpecificationsObject<FavType[]>;
|
|
885
873
|
|
|
886
874
|
/**
|
|
887
875
|
* Contains information, that registration hash for pushNotifications has been
|
|
@@ -904,6 +892,16 @@ export interface DataSpecifications {
|
|
|
904
892
|
* User has enabled advanced features in debug console
|
|
905
893
|
*/
|
|
906
894
|
advancedDebugConsole: DataSpecificationsObject<boolean>;
|
|
895
|
+
|
|
896
|
+
/**
|
|
897
|
+
* Installed version of windy idb
|
|
898
|
+
*/
|
|
899
|
+
installedIdbVersion: DataSpecificationsObject<number>;
|
|
900
|
+
|
|
901
|
+
/**
|
|
902
|
+
* Active tab in pin menu (fav-layers plugin)
|
|
903
|
+
*/
|
|
904
|
+
pinMenuActiveTab: DataSpecificationsObject<'models' | 'layers'>;
|
|
907
905
|
}
|
|
908
906
|
|
|
909
907
|
/**
|
|
@@ -924,7 +922,7 @@ export type PickDataSpecificationPropsByType<U, Strict = true> = Pick<
|
|
|
924
922
|
: never
|
|
925
923
|
: never
|
|
926
924
|
: U extends DataSpecifications[P]['def']
|
|
927
|
-
|
|
928
|
-
|
|
925
|
+
? P
|
|
926
|
+
: never;
|
|
929
927
|
}[keyof DataSpecifications]
|
|
930
928
|
>;
|
|
@@ -1,32 +1,25 @@
|
|
|
1
|
-
import type { RouteType, StationId, Timestamp } from '@windy/types';
|
|
2
|
-
import type { LatLon
|
|
1
|
+
import type { ISOCountryCode, RouteType, StationId, Timestamp } from '@windy/types';
|
|
2
|
+
import type { LatLon } from '@windy/interfaces';
|
|
3
3
|
|
|
4
4
|
export type FavId = string;
|
|
5
5
|
|
|
6
6
|
/** New fav type not including alerts */
|
|
7
|
-
export type
|
|
8
|
-
|
|
9
|
-
/** @deprecated Old fav type including alert that will be abandoned soon */
|
|
10
|
-
export type FavType = FavTypeNew | 'alert';
|
|
7
|
+
export type FavType = 'fav' | 'airport' | 'station' | 'webcam' | 'route';
|
|
11
8
|
|
|
12
9
|
export type RouteAsString = `${RouteType}/${string}`;
|
|
13
10
|
|
|
14
11
|
export type FavFragment = (LatLon & {
|
|
15
12
|
/** Title of the fav */
|
|
16
13
|
title: string;
|
|
14
|
+
|
|
15
|
+
/** Lowercase ISO 2 letter CC or xx if fav is in the ocean for example */
|
|
16
|
+
cc?: ISOCountryCode | 'xx';
|
|
17
17
|
}) &
|
|
18
18
|
(
|
|
19
19
|
| { type: 'fav' }
|
|
20
20
|
|
|
21
|
-
/** @deprecated use till migration of alerts is in process */
|
|
22
|
-
| {
|
|
23
|
-
type: 'alert';
|
|
24
|
-
alert: Alert;
|
|
25
|
-
alertProps: AlertProps;
|
|
26
|
-
}
|
|
27
|
-
|
|
28
21
|
/** Airport ICAO code in case of airport */
|
|
29
|
-
| { type: 'airport'; icao: string }
|
|
22
|
+
| { type: 'airport'; icao: string; iata?: string }
|
|
30
23
|
|
|
31
24
|
/** Weather station ID (if WX station) */
|
|
32
25
|
| { type: 'station'; stationId: StationId }
|
|
@@ -56,10 +49,6 @@ export type Fav = FavFragment & {
|
|
|
56
49
|
updated: Timestamp;
|
|
57
50
|
};
|
|
58
51
|
|
|
59
|
-
export type ObsoleteFav = FavFragment & {
|
|
60
|
-
key: string;
|
|
61
|
-
};
|
|
62
|
-
|
|
63
52
|
export type FavQuery =
|
|
64
53
|
| { webcamsId: number }
|
|
65
54
|
| { stationId: StationId }
|
|
@@ -59,6 +59,11 @@ export interface HttpOptions {
|
|
|
59
59
|
* Custom headers object
|
|
60
60
|
*/
|
|
61
61
|
customHeaders?: Record<string, string>;
|
|
62
|
+
|
|
63
|
+
/**
|
|
64
|
+
* Use already prepared and ongoing fetch requests if available
|
|
65
|
+
*/
|
|
66
|
+
ongoingFetchRequest?: ReturnType<typeof fetch>;
|
|
62
67
|
}
|
|
63
68
|
|
|
64
69
|
/**
|
|
@@ -1,7 +1,10 @@
|
|
|
1
1
|
import { Fav, FavId } from '@windy/favs.d';
|
|
2
2
|
import { StartupArticleData, WhatsNewData } from '@windy/startup.d';
|
|
3
|
-
import {
|
|
4
|
-
|
|
3
|
+
import {
|
|
4
|
+
HiddenReasonType,
|
|
5
|
+
ReasonTypes,
|
|
6
|
+
SubscriptionSource,
|
|
7
|
+
} from '@plugins/subscription/subscription';
|
|
5
8
|
import { HttpPayload } from '@windy/http.d';
|
|
6
9
|
import {
|
|
7
10
|
CapAlertHeadline,
|
|
@@ -11,6 +14,7 @@ import {
|
|
|
11
14
|
PickerCoords,
|
|
12
15
|
SummaryDataHash,
|
|
13
16
|
WeatherDataPayload,
|
|
17
|
+
FullRenderParameters,
|
|
14
18
|
} from '@windy/interfaces.d';
|
|
15
19
|
import { Pois, Products } from '@windy/rootScope.d';
|
|
16
20
|
import { SingleClickParams } from '@windy/singleclick.d';
|
|
@@ -25,7 +29,6 @@ import { WebcamCategoryType } from '@windy/webcams';
|
|
|
25
29
|
|
|
26
30
|
import type { StoryPreview } from '@plugins/stories/stories.d';
|
|
27
31
|
import type { StationDisplayType } from '@plugins/station/station';
|
|
28
|
-
import type { PluginsListResponseDto } from '@plugins/external-plugins/external-plugins';
|
|
29
32
|
|
|
30
33
|
/**
|
|
31
34
|
* Type of source event, that led to opening any plugin
|
|
@@ -108,7 +111,8 @@ type RplannerDistanceParams =
|
|
|
108
111
|
| {
|
|
109
112
|
import: boolean;
|
|
110
113
|
content: string;
|
|
111
|
-
}
|
|
114
|
+
} // Uploaded GPX
|
|
115
|
+
| undefined;
|
|
112
116
|
|
|
113
117
|
export type PickerOpenParams =
|
|
114
118
|
| (PluginSource &
|
|
@@ -121,7 +125,7 @@ export type PluginsOpenParams = {
|
|
|
121
125
|
detail: DetailOpenParams;
|
|
122
126
|
picker: PickerOpenParams;
|
|
123
127
|
'picker-mobile': PickerOpenParams;
|
|
124
|
-
favs: PluginSource
|
|
128
|
+
favs: PluginSource;
|
|
125
129
|
station: PluginSource & {
|
|
126
130
|
id: string;
|
|
127
131
|
moveToTimestamp?: Timestamp;
|
|
@@ -145,16 +149,20 @@ export type PluginsOpenParams = {
|
|
|
145
149
|
name?: string;
|
|
146
150
|
};
|
|
147
151
|
contextmenu: PluginSource & LatLon & { containerPoint?: L.Point };
|
|
152
|
+
|
|
153
|
+
/**
|
|
154
|
+
* Typing is incorrect here. If called from ClickHandler it has a string as params
|
|
155
|
+
*/
|
|
148
156
|
subscription:
|
|
149
|
-
|
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
157
|
+
| PluginSource
|
|
158
|
+
| (PluginSource &
|
|
159
|
+
(
|
|
160
|
+
| { promote?: ReasonTypes | HiddenReasonType; subsSource: SubscriptionSource }
|
|
161
|
+
| { pendingError: Error & { responseText: string } }
|
|
162
|
+
));
|
|
154
163
|
'alerts-edit': PluginSource &
|
|
155
164
|
(
|
|
156
165
|
| { action: 'edit'; id: string }
|
|
157
|
-
| { action: 'migration'; favId: string }
|
|
158
166
|
| {
|
|
159
167
|
action: 'new';
|
|
160
168
|
lat: number;
|
|
@@ -174,11 +182,7 @@ export type PluginsOpenParams = {
|
|
|
174
182
|
'nearest-webcams-mobile': PluginSource & LatLon;
|
|
175
183
|
'nearest-webcams': PluginSource & LatLon;
|
|
176
184
|
'external-plugins':
|
|
177
|
-
| (PluginSource & {
|
|
178
|
-
id?: string;
|
|
179
|
-
qs?: PluginsQsParams['external-plugins'];
|
|
180
|
-
installPlugin?: PluginsListResponseDto;
|
|
181
|
-
})
|
|
185
|
+
| (PluginSource & { id?: string; qs?: PluginsQsParams['external-plugins'] })
|
|
182
186
|
| undefined;
|
|
183
187
|
sounding: PluginSource & LatLon & { name?: string };
|
|
184
188
|
radiosonde: PluginSource & { id: string; lat?: number; lon?: number };
|
|
@@ -23,3 +23,5 @@ export type SupportedLanguages = (typeof import('./rootScope').supportedLanguage
|
|
|
23
23
|
export type Pois = keyof typeof import('./rootScope').pois;
|
|
24
24
|
|
|
25
25
|
export type Isolines = (typeof import('./rootScope').isolinesType)[number];
|
|
26
|
+
|
|
27
|
+
export type PollenProducts = keyof typeof import('./rootScope').pollenProducts;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
+
import { HttpPayload } from '@windy/http.d';
|
|
1
2
|
import { LatLon } from '@windy/interfaces.d';
|
|
2
3
|
import { Timestamp } from '@windy/types.d';
|
|
3
|
-
import { HttpPayload } from '@windy/http.d';
|
|
4
4
|
|
|
5
5
|
export type WebcamCategoryType =
|
|
6
6
|
| 'landscape'
|
|
@@ -75,7 +75,6 @@ export interface WebcamImageUrls {
|
|
|
75
75
|
normal: string;
|
|
76
76
|
original: string;
|
|
77
77
|
preview: string;
|
|
78
|
-
teaserbg: string;
|
|
79
78
|
thumbnail: string;
|
|
80
79
|
webcam: string;
|
|
81
80
|
}
|
|
@@ -83,6 +82,8 @@ export interface WebcamImageUrls {
|
|
|
83
82
|
export type WebcamImageSize = keyof WebcamImageUrls;
|
|
84
83
|
|
|
85
84
|
export type WebcamTimelapseType = 'day' | 'current' | 'all';
|
|
85
|
+
|
|
86
|
+
// FIXME TODO: This type does not correspond to output form a backend. Fix the type
|
|
86
87
|
export interface WebcamDetail {
|
|
87
88
|
categories: WebcamCategoryType[];
|
|
88
89
|
contacts: { owner: string; caretaker: string };
|
|
@@ -153,6 +154,12 @@ export interface WebcamLastUpdatedOn {
|
|
|
153
154
|
lastUpdatedOn: number[];
|
|
154
155
|
}
|
|
155
156
|
|
|
157
|
+
export interface WebcamImageRequestParams {
|
|
158
|
+
webcamId: string | number;
|
|
159
|
+
state?: 'current' | 'daylight';
|
|
160
|
+
size?: WebcamImageSize;
|
|
161
|
+
}
|
|
162
|
+
|
|
156
163
|
export interface WebcamMetadata {
|
|
157
164
|
updateString: string;
|
|
158
165
|
recencyClass: string;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Loader service for new rendering engine
|
|
3
3
|
*/
|
|
4
|
-
import type { TransformFunction } from '@windy/
|
|
5
|
-
import type { TileParams } from '@windy/Renderer
|
|
4
|
+
import type { TransformFunction } from '@windy/types';
|
|
5
|
+
import type { TileParams } from '@windy/Renderer';
|
|
6
6
|
export declare class DataTile {
|
|
7
7
|
url: string;
|
|
8
8
|
status: 'undefined' | 'loaded' | 'loading' | 'failed';
|
package/types/client/embed.d.ts
CHANGED
|
@@ -47,7 +47,6 @@ export * as trans from './services/trans';
|
|
|
47
47
|
export * as query from './ui/query';
|
|
48
48
|
export * as rhMessage from './ui/rhMessage';
|
|
49
49
|
export * as BottomSlide from './uiClasses/BottomSlide';
|
|
50
|
-
export * as ClickHandler from './uiClasses/ClickHandler';
|
|
51
50
|
export * as Drag from './uiClasses/Drag';
|
|
52
51
|
export * as Swipe from './uiClasses/Swipe';
|
|
53
52
|
export * as Window from './uiClasses/Window';
|
|
@@ -65,6 +64,5 @@ export * as models from './weather/models';
|
|
|
65
64
|
export { default as products } from './weather/products';
|
|
66
65
|
export * as Calendar from './weatherClasses/Calendar';
|
|
67
66
|
export * as Color from './weatherClasses/Color';
|
|
68
|
-
export * as IconProducts from './weatherClasses/IconProducts';
|
|
69
67
|
export { default as GlObj } from './wgUtils/GlObj';
|
|
70
68
|
export { $, bcast as broadcast, ga, overlays, store };
|
|
@@ -1,6 +1,8 @@
|
|
|
1
|
+
import { ExternalSveltePlugin } from '@windy/ExternalSveltePlugin';
|
|
1
2
|
import type { InstalledExternalPluginConfig } from '@windy/interfaces.d';
|
|
2
3
|
export type ExternalPluginError = {
|
|
3
4
|
type: 'network' | 'installation' | 'open';
|
|
4
5
|
msg: string;
|
|
5
6
|
};
|
|
6
7
|
export declare const installExternalPlugin: (url: string, installedBy: InstalledExternalPluginConfig['installedBy']) => Promise<InstalledExternalPluginConfig | ExternalPluginError>;
|
|
8
|
+
export declare const loadExternalPlugins: (forceReload?: boolean) => Promise<ExternalSveltePlugin[]>;
|
package/types/client/fetch.d.ts
CHANGED
|
@@ -10,10 +10,14 @@
|
|
|
10
10
|
*/
|
|
11
11
|
import * as http from '@windy/http';
|
|
12
12
|
import type { CityTemperaturesDto } from '@windy-types/citytile2';
|
|
13
|
-
import type { DataHash, LatLon, MeteogramDataPayload, WeatherDataPayload, CapAlertHeadline, ActiveStormCountPayload } from '@windy/interfaces.d';
|
|
13
|
+
import type { DataHash, LatLon, MeteogramDataPayload, WeatherDataPayload, CapAlertHeadline, ActiveStormCountPayload, AirQDataHash } from '@windy/interfaces.d';
|
|
14
14
|
import type { Pois, Products } from '@windy/rootScope.d';
|
|
15
|
-
import type {
|
|
15
|
+
import type { SatelliteInfoJson } from '@windy/satellite.d';
|
|
16
|
+
import type { RadarMinifest } from '@plugins/radar/types';
|
|
17
|
+
import type { ExtendedStationType, Pixel, StationOrPoiType } from '@windy/types';
|
|
18
|
+
import type { OSMMapBounds } from '@plugins/search/search.d';
|
|
16
19
|
import type { HttpOptions, HttpPayload, QueryStringSource } from '@windy/http.d';
|
|
20
|
+
import type { StormListJSON } from '@plugins/_shared/hurricanes/types';
|
|
17
21
|
interface LatLonStep extends LatLon {
|
|
18
22
|
step?: number;
|
|
19
23
|
interpolate?: boolean;
|
|
@@ -80,7 +84,7 @@ export declare const getPointForecastUrl: <T extends LatLonStep>(model: Products
|
|
|
80
84
|
* @param httpOptions Additional HTTP options
|
|
81
85
|
* @returns Promise with HTTP payload
|
|
82
86
|
*/
|
|
83
|
-
export declare const getPointForecastData: <T extends LatLonStep>(model: Products, latLonStepInterpolate: T, pointForecastOptions?: Record<string, string>, httpOptions?: HttpOptions) => Promise<HttpPayload<WeatherDataPayload<
|
|
87
|
+
export declare const getPointForecastData: <K extends DataHash | AirQDataHash = DataHash, T extends LatLonStep = LatLonStep>(model: Products, latLonStepInterpolate: T, pointForecastOptions?: Record<string, string>, httpOptions?: HttpOptions) => Promise<http.HttpPayload<WeatherDataPayload<K>>>;
|
|
84
88
|
/**
|
|
85
89
|
* Gets enhanced point forecast meteogram data for given location
|
|
86
90
|
* @returns Promise with HTTP payload
|
|
@@ -125,10 +129,30 @@ export declare const getObservationsUrl: (type: ExtendedStationType, id: string,
|
|
|
125
129
|
/**
|
|
126
130
|
* Get URL for getting observations for a specific station in node-poi server
|
|
127
131
|
*/
|
|
128
|
-
export declare const getObservationPoiUrl: (type: StationOrPoiType | 'stations', id: string) => string;
|
|
132
|
+
export declare const getObservationPoiUrl: (type: StationOrPoiType | 'stations' | 'metars', id: string) => string;
|
|
129
133
|
/**
|
|
130
134
|
* Returns loading promise for cap alert headlines
|
|
131
135
|
*/
|
|
132
136
|
export declare const getCapAlertsSummary: ({ lat, lon }: LatLon) => Promise<http.HttpPayload<CapAlertHeadline[]>>;
|
|
133
137
|
export declare const getHurricanesCount: () => Promise<HttpPayload<ActiveStormCountPayload>>;
|
|
138
|
+
/**
|
|
139
|
+
* Loads Satellite Product info
|
|
140
|
+
*/
|
|
141
|
+
export declare const getSatelliteInfo: () => Promise<HttpPayload<SatelliteInfoJson>>;
|
|
142
|
+
/**
|
|
143
|
+
* Loads Radar Product info
|
|
144
|
+
*/
|
|
145
|
+
export declare const getRadarInfo: () => Promise<HttpPayload<RadarMinifest>>;
|
|
146
|
+
export declare const getRadarArchiveInfo: () => Promise<HttpPayload<RadarMinifest>>;
|
|
147
|
+
export declare const getSatelliteArchiveInfo: () => Promise<HttpPayload<SatelliteInfoJson>>;
|
|
148
|
+
export declare const getRadarCoverage: () => Promise<HttpPayload<number[]>>;
|
|
149
|
+
export declare const getHurricanesList: () => Promise<HttpPayload<StormListJSON>>;
|
|
150
|
+
/**
|
|
151
|
+
* Returns URL for static map image. Max zoom level is 13
|
|
152
|
+
*/
|
|
153
|
+
export declare const getStaticMapImageUrl: (params: LatLon & {
|
|
154
|
+
zoom: 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13;
|
|
155
|
+
size: Pixel;
|
|
156
|
+
bounds?: OSMMapBounds;
|
|
157
|
+
}) => string;
|
|
134
158
|
export {};
|
package/types/client/format.d.ts
CHANGED
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
*/
|
|
6
6
|
import type { DirectionFunction, HowOldOptions, TimeFormatFunction } from './d.ts.files/format.d';
|
|
7
7
|
import type { Timestamp } from './d.ts.files/types';
|
|
8
|
+
export declare const euTime: TimeFormatFunction;
|
|
8
9
|
/**
|
|
9
10
|
* Returns function for displaying hours (either 12,24h format) on a basis of locale store of a browser
|
|
10
11
|
* US, UK, PH, CA, AU, NZ, IN, EG, SA, CO, PK, MY - AM,PM format
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { ExtendedWebGLTexture, WebGLProgramObject } from '@windy/GlObj.d';
|
|
2
|
-
import type { TileParams } from '@windy/Renderer
|
|
2
|
+
import type { TileParams } from '@windy/Renderer';
|
|
3
3
|
import type { TileLayerCanvas } from '@windy/TileLayerCanvas.d';
|
|
4
4
|
import type { DataTile } from '@windy/dataLoader';
|
|
5
5
|
export type Gradient = {
|
|
@@ -136,12 +136,6 @@ declare class TileRenderer {
|
|
|
136
136
|
* @returns texture with additional params
|
|
137
137
|
*/
|
|
138
138
|
private createGradientObject;
|
|
139
|
-
/**
|
|
140
|
-
* Predefined alpha values are set to gradient and then color array is generated
|
|
141
|
-
* (solution for user gradient colors with bad alpha)
|
|
142
|
-
* @param colorObj
|
|
143
|
-
*/
|
|
144
|
-
private augmentRainCoverColorsWithAlpha;
|
|
145
139
|
/**
|
|
146
140
|
* Prepare color gradient(s) for layer
|
|
147
141
|
* @param layer
|