@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
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { RegistrationHash } from '@windy/pushNotifications';
|
|
1
2
|
/**
|
|
2
3
|
* Deactivates current device from push notif backend
|
|
3
4
|
*
|
|
@@ -10,4 +11,4 @@ export declare const deactivateCurrentDevice: () => Promise<void>;
|
|
|
10
11
|
* @param registrationHash Push notification registration hash
|
|
11
12
|
* @returns
|
|
12
13
|
*/
|
|
13
|
-
export declare const saveCurrentDevice: (registrationHash
|
|
14
|
+
export declare const saveCurrentDevice: (registrationHash?: RegistrationHash | null) => Promise<void>;
|
package/types/client/embed2.d.ts
CHANGED
|
@@ -1,8 +1,6 @@
|
|
|
1
|
-
/// <reference types="@windy/declarations/windy-modules" />
|
|
2
1
|
import './utils/errorLogger';
|
|
3
2
|
import './leafletExt/CanvasLayer';
|
|
4
3
|
import './services/params';
|
|
5
|
-
import './pluginSystem/BottomTagPlugin';
|
|
6
4
|
import './pluginSystem/Plugin';
|
|
7
5
|
import './pluginSystem/SveltePlugin';
|
|
8
6
|
import './pluginSystem/TagPlugin';
|
|
@@ -12,27 +10,27 @@ import './ui/components';
|
|
|
12
10
|
import './ui/timeAnimation';
|
|
13
11
|
import './ui/visibility';
|
|
14
12
|
import './render/renderTile';
|
|
15
|
-
import './render/
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
export
|
|
24
|
-
import 'virtual:langEn';
|
|
13
|
+
import './render/tileLayerInstance';
|
|
14
|
+
export * as detectDevice from './dummyModules/detectDevice';
|
|
15
|
+
export * as log from './dummyModules/log';
|
|
16
|
+
export * as promo from './dummyModules/promo';
|
|
17
|
+
export * as seoParser from './dummyModules/seoParser';
|
|
18
|
+
export * as location from './dummyModules/location';
|
|
19
|
+
export * as router from './dummyModules/router';
|
|
20
|
+
export * as showableErrorsService from './dummyModules/showableErrorsService';
|
|
21
|
+
export * as userFavs from './dummyModules/userFavs';
|
|
25
22
|
import bcast from './services/broadcast';
|
|
26
23
|
import * as rootScope from './services/rootScope';
|
|
27
24
|
import { default as store } from './services/store';
|
|
25
|
+
export * as user from './services/user';
|
|
28
26
|
import * as ga from './utils/ga';
|
|
29
27
|
import { $ } from './utils/utils';
|
|
30
28
|
import { default as overlays } from './weather/overlays';
|
|
31
29
|
export { rootScope };
|
|
32
|
-
export * as progressBar from '../plugins/progress-bar/progress-bar';
|
|
33
|
-
export * as location from './dummyModules/location';
|
|
34
|
-
export * as router from './dummyModules/router';
|
|
35
30
|
export * as map from './map/map';
|
|
31
|
+
export * as baseMap from './map/baseMap';
|
|
32
|
+
export * as cityLabels from './map/cityLabels';
|
|
33
|
+
export * as mapGlobeCtrl from './map/mapGlobeCtrl';
|
|
36
34
|
export * as picker from './map/picker';
|
|
37
35
|
export * as singleclick from './map/singleclick';
|
|
38
36
|
export { default as plugins } from './pluginSystem/plugins';
|
|
@@ -44,32 +42,17 @@ export { default as colors } from './services/colors';
|
|
|
44
42
|
export * as connection from './services/connection';
|
|
45
43
|
export * as device from './services/device';
|
|
46
44
|
export * as geolocation from './services/geolocation';
|
|
47
|
-
export
|
|
45
|
+
export * as notifications from './services/notifications';
|
|
48
46
|
export * as pois from './services/pois';
|
|
49
47
|
export * as reverseName from './services/reverseName';
|
|
50
|
-
export * as showableErrorsService from './services/showableErrorsService';
|
|
51
48
|
export * as trans from './services/trans';
|
|
52
49
|
export * as startupWeather from './ui/startupWeather';
|
|
53
|
-
export * as promo from './ui/promo';
|
|
54
50
|
export * as query from './ui/query';
|
|
55
51
|
export * as rhMessage from './ui/rhMessage';
|
|
56
|
-
export * as user from './ui/user';
|
|
57
|
-
export * as BindedBar from './uiClasses/BindedBar';
|
|
58
|
-
export * as BindedCheckbox from './uiClasses/BindedCheckbox';
|
|
59
|
-
export * as BindedSwitch from './uiClasses/BindedSwitch';
|
|
60
52
|
export * as BottomSlide from './uiClasses/BottomSlide';
|
|
61
53
|
export * as ClickHandler from './uiClasses/ClickHandler';
|
|
62
54
|
export * as Drag from './uiClasses/Drag';
|
|
63
|
-
export * as DraggableDiv from './uiClasses/DraggableDiv';
|
|
64
|
-
export * as GhostBox from './uiClasses/GhostBox';
|
|
65
|
-
export * as Legend from './uiClasses/Legend';
|
|
66
|
-
export * as LongTap from './uiClasses/LongTap';
|
|
67
|
-
export * as MobileCalendar from './uiClasses/MobileCalendar';
|
|
68
|
-
export * as ProductSwitch from './uiClasses/ProductSwitch';
|
|
69
|
-
export * as Scrollable from './uiClasses/Scrollable';
|
|
70
55
|
export * as Swipe from './uiClasses/Swipe';
|
|
71
|
-
export * as Switch from './uiClasses/Switch';
|
|
72
|
-
export * as TimestampBar from './uiClasses/TimestampBar';
|
|
73
56
|
export * as Window from './uiClasses/Window';
|
|
74
57
|
export * as Evented from './utils/Evented';
|
|
75
58
|
export * as errorLogger from './utils/errorLogger';
|
package/types/client/fetch.d.ts
CHANGED
|
@@ -1,16 +1,12 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
import type { DataHash, LatLon, MeteogramDataPayload, WeatherDataPayload } from '@windy/interfaces.d';
|
|
1
|
+
import type { CityTemperaturesDto } from '@windy-types/citytile2';
|
|
2
|
+
import type { DataHash, LatLon, MeteogramDataPayload, WeatherDataPayload, ActiveStormCountPayload } from '@windy/interfaces.d';
|
|
3
3
|
import type { Pois, Products } from '@windy/rootScope.d';
|
|
4
|
-
import type { ExtendedStationType } from '@windy/types';
|
|
5
|
-
import type { HttpOptions, HttpPayload } from './http.d';
|
|
4
|
+
import type { ExtendedStationType, StationOrPoiType } from '@windy/types';
|
|
5
|
+
import type { HttpOptions, HttpPayload, QueryStringSource } from './http.d';
|
|
6
6
|
interface LatLonStep extends LatLon {
|
|
7
7
|
step?: number;
|
|
8
8
|
interpolate?: boolean;
|
|
9
9
|
}
|
|
10
|
-
/**
|
|
11
|
-
* @ignore
|
|
12
|
-
*/
|
|
13
|
-
export declare const getReftimeIso: (model: Products) => any;
|
|
14
10
|
/**
|
|
15
11
|
* Returns URL for webcam detail by id
|
|
16
12
|
*
|
|
@@ -54,6 +50,16 @@ export declare const getSearchWebcamViewsUrl: (textQuery: string, latLon?: LatLo
|
|
|
54
50
|
* @ignore
|
|
55
51
|
*/
|
|
56
52
|
export declare const getWebcamMetricsUrl: (id: string | number) => string;
|
|
53
|
+
/**
|
|
54
|
+
* Gets point forecast data URL for given location
|
|
55
|
+
*
|
|
56
|
+
* @param model Forecast model
|
|
57
|
+
* @param params LalLon of the location and additional parameters
|
|
58
|
+
* @param pointForecastOptions Additional options of point forecast API
|
|
59
|
+
* @param httpOptions Additional HTTP options
|
|
60
|
+
* @returns URL string for getting point forecast data
|
|
61
|
+
*/
|
|
62
|
+
export declare const getPointForecastUrl: <T extends LatLonStep>(model: Products, { lat, lon, step, interpolate }: T, pointForecastOptions?: Record<string, string>) => Promise<string>;
|
|
57
63
|
/**
|
|
58
64
|
* Gets point forecast data for given location
|
|
59
65
|
*
|
|
@@ -63,34 +69,33 @@ export declare const getWebcamMetricsUrl: (id: string | number) => string;
|
|
|
63
69
|
* @param httpOptions Additional HTTP options
|
|
64
70
|
* @returns Promise with HTTP payload
|
|
65
71
|
*/
|
|
66
|
-
export declare const getPointForecastData: <T extends LatLonStep>(model: Products,
|
|
72
|
+
export declare const getPointForecastData: <T extends LatLonStep>(model: Products, latLonStepInterpolate: T, pointForecastOptions?: Record<string, string>, httpOptions?: HttpOptions) => Promise<HttpPayload<WeatherDataPayload<DataHash>>>;
|
|
67
73
|
/**
|
|
68
74
|
* Gets enhanced point forecast meteogram data for given location
|
|
69
75
|
* @returns Promise with HTTP payload
|
|
70
76
|
*/
|
|
71
|
-
export declare const
|
|
77
|
+
export declare const getMeteogramForecastUrl: <T extends LatLonStep>(model: Products, { lat, lon, step }: T, pointForecastOptions?: Record<string, string>) => Promise<string>;
|
|
72
78
|
/**
|
|
73
|
-
*
|
|
74
|
-
* @
|
|
79
|
+
* Gets enhanced point forecast meteogram data for given location
|
|
80
|
+
* @returns Promise with HTTP payload
|
|
75
81
|
*/
|
|
76
|
-
export declare const
|
|
82
|
+
export declare const getMeteogramForecastData: <T extends LatLonStep>(model: Products, latLonStep: T, pointForecastOptions?: Record<string, string>, httpOptions?: HttpOptions) => Promise<HttpPayload<MeteogramDataPayload>>;
|
|
77
83
|
/**
|
|
78
84
|
* Returns URL for getting citytile forecast
|
|
79
85
|
*
|
|
80
86
|
* @param model Forecast model
|
|
81
87
|
* @param frag Mercator frag in {z}/{x}/{y} format
|
|
82
|
-
* @param options HTTP options
|
|
83
88
|
* @returns URL for getting citytile forecast
|
|
84
89
|
* @ignore
|
|
85
90
|
*/
|
|
86
|
-
export declare const getCitytileData: (model: Products, frag: string
|
|
91
|
+
export declare const getCitytileData: (model: Products, frag: string) => Promise<HttpPayload<CityTemperaturesDto> | null>;
|
|
87
92
|
/**
|
|
88
93
|
* Returns URL for nearest POI items (stations, airQ, ...)
|
|
89
94
|
* @param param0
|
|
90
95
|
* @returns URL for getting nearest POI items
|
|
91
96
|
* @ignore
|
|
92
97
|
*/
|
|
93
|
-
export declare const getNearestPoiItemsUrl: (type: Pois | 'stations', { lat, lon }: LatLon) => string;
|
|
98
|
+
export declare const getNearestPoiItemsUrl: (type: Pois | 'stations', { lat, lon }: LatLon, options?: QueryStringSource) => string;
|
|
94
99
|
/**
|
|
95
100
|
* Returns URL for tide forecast
|
|
96
101
|
* @ignore
|
|
@@ -106,4 +111,12 @@ export declare const getTidePoiUrl: (id: string) => string;
|
|
|
106
111
|
* @ignore
|
|
107
112
|
*/
|
|
108
113
|
export declare const getObservationsUrl: (type: ExtendedStationType, id: string, daysFrom: number, daysTo?: number) => string;
|
|
114
|
+
/**
|
|
115
|
+
* Get URL for getting observations for a specific station in node-poi server
|
|
116
|
+
*/
|
|
117
|
+
export declare const getObservationPoiUrl: (type: StationOrPoiType | 'stations', id: string) => string;
|
|
118
|
+
/**
|
|
119
|
+
* Returns http promise for active hurricanes count
|
|
120
|
+
*/
|
|
121
|
+
export declare const getHurricanesCount: () => Promise<HttpPayload<ActiveStormCountPayload>>;
|
|
109
122
|
export {};
|
package/types/client/ga.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import '@windy/router';
|
|
2
2
|
import type { GeolocationInfo, HomeLocation } from '@windy/interfaces.d';
|
|
3
|
+
import type { PositionOptions } from '@capacitor/geolocation';
|
|
3
4
|
/**
|
|
4
5
|
* Returns either GPS or IP location whichever is newer.
|
|
5
6
|
*
|
|
@@ -10,13 +11,21 @@ import type { GeolocationInfo, HomeLocation } from '@windy/interfaces.d';
|
|
|
10
11
|
* @returns Location got from GPS or IP, the newer is preferred
|
|
11
12
|
*/
|
|
12
13
|
export declare const getMyLatestPos: () => GeolocationInfo;
|
|
14
|
+
interface GeolocationOptions extends PositionOptions {
|
|
15
|
+
doNotShowSearchGPSMessage?: boolean;
|
|
16
|
+
doNotShowFailureMessage?: boolean;
|
|
17
|
+
getMeFallbackGps?: boolean;
|
|
18
|
+
}
|
|
13
19
|
/**
|
|
14
20
|
* Returns promise on GPS based location with GeoIP location as a fallback.
|
|
15
21
|
*
|
|
16
|
-
*
|
|
22
|
+
* Enables to display information messages to user by default, and enables to
|
|
23
|
+
* get fallback GPS location if GPS location is not available.
|
|
24
|
+
*
|
|
25
|
+
* @param options Options for geolocation
|
|
17
26
|
* @returns Geolocation info from GPS, GeoIP as a fallback
|
|
18
27
|
*/
|
|
19
|
-
export declare const getGPSlocation: (options?:
|
|
28
|
+
export declare const getGPSlocation: (options?: GeolocationOptions) => Promise<GeolocationInfo>;
|
|
20
29
|
/**
|
|
21
30
|
* Returns fallback name created from lat,lon if nothing else can be used
|
|
22
31
|
*
|
|
@@ -28,10 +37,9 @@ export declare const getGPSlocation: (options?: PositionOptions) => Promise<Geol
|
|
|
28
37
|
*/
|
|
29
38
|
export declare const getFallbackName: (lat: number | string, lon: number | string) => string;
|
|
30
39
|
/**
|
|
31
|
-
* Gets accurate home location. Cannot be used in map initialization
|
|
32
|
-
*
|
|
33
|
-
* @param cb Callback function to call when location is get. Location info object is passed as a callback argument
|
|
34
|
-
*
|
|
40
|
+
* Gets accurate home location. Cannot be used in map initialization because it is async.
|
|
35
41
|
* @ignore
|
|
36
42
|
*/
|
|
37
|
-
export declare const getHomeLocation: (
|
|
43
|
+
export declare const getHomeLocation: () => Promise<GeolocationInfo | HomeLocation>;
|
|
44
|
+
export declare function requestLocationPermissions(): Promise<boolean>;
|
|
45
|
+
export {};
|
package/types/client/http.d.ts
CHANGED
|
@@ -2,6 +2,15 @@
|
|
|
2
2
|
* HTTP fetch lib using Promises, authorization and lru caching
|
|
3
3
|
*/
|
|
4
4
|
import type { HttpOptions, HttpPayload } from './d.ts.files/http.d';
|
|
5
|
+
/**
|
|
6
|
+
* Type of the string, that will be added to the header in Accept line to increase stealing protection a little bit
|
|
7
|
+
*
|
|
8
|
+
* Target mobile: Use legacy header format until mobile apps start sending correct origin to pass CORS check on the server
|
|
9
|
+
*/
|
|
10
|
+
export declare const acceptHeader: string;
|
|
11
|
+
/**
|
|
12
|
+
* Enhances URL with server, tokens and auth counter
|
|
13
|
+
*/
|
|
5
14
|
export declare const getURL: (url: string) => string;
|
|
6
15
|
export declare class HttpError extends Error {
|
|
7
16
|
status: number;
|
|
@@ -51,6 +60,14 @@ export declare const post: StandardHttpRequestFun;
|
|
|
51
60
|
* @returns HTTP payload or null when anything failed
|
|
52
61
|
*/
|
|
53
62
|
export declare const put: StandardHttpRequestFun;
|
|
63
|
+
/**
|
|
64
|
+
* Make PATCH http request
|
|
65
|
+
*
|
|
66
|
+
* @param url Url
|
|
67
|
+
* @param options Options
|
|
68
|
+
* @returns HTTP payload or null when anything failed
|
|
69
|
+
*/
|
|
70
|
+
export declare const patch: StandardHttpRequestFun;
|
|
54
71
|
/**
|
|
55
72
|
* Make HEAD http request
|
|
56
73
|
*
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import { IDB } from '@windy/IDB';
|
|
2
|
+
import type { Fav } from '@windy/favs.d';
|
|
3
|
+
import type { SearchRecent } from '@plugins/search/search';
|
|
4
|
+
import type { AlertResponse, AlertRequest } from '@windy/alerts';
|
|
5
|
+
import type { MarkedNotams } from '@plugins/airport/airport';
|
|
6
|
+
import type { MinifestObject } from '@windy/Calendar.d';
|
|
7
|
+
import type { SeenArticle } from '@windy/startup.d';
|
|
8
|
+
import type { PromoInfoObject } from '@windy/promo';
|
|
9
|
+
import type { AnyColorIdent, UserColor } from '@windy/Color.d';
|
|
10
|
+
export declare const initPromise: Promise<IDBDatabase>;
|
|
11
|
+
/** Db of stored user favourites */
|
|
12
|
+
export declare const userFavsIdb: IDB<string, Fav, import("../../types/interfaces").LatLon & {
|
|
13
|
+
title: string;
|
|
14
|
+
} & ({
|
|
15
|
+
type: "fav";
|
|
16
|
+
} | {
|
|
17
|
+
type: "alert";
|
|
18
|
+
alert: import("../../types/interfaces").Alert;
|
|
19
|
+
alertProps: import("../../types/interfaces").AlertProps;
|
|
20
|
+
} | {
|
|
21
|
+
type: "airport";
|
|
22
|
+
icao: string;
|
|
23
|
+
} | {
|
|
24
|
+
type: "station";
|
|
25
|
+
stationId: `radiation-${string}` | `airq-${string}` | `ad-${string}` | `wmo-${string}` | `madis-${string}` | `buoy-${string}` | `dbuoy-${string}` | `pws-${string}` | `ship-${string}`;
|
|
26
|
+
} | {
|
|
27
|
+
type: "webcam";
|
|
28
|
+
webcamId: number;
|
|
29
|
+
} | {
|
|
30
|
+
type: "route";
|
|
31
|
+
route: `car/${string}` | `vfr/${string}` | `ifr/${string}` | `elevation/${string}` | `boat/${string}` | `airgram/${string}`;
|
|
32
|
+
})>;
|
|
33
|
+
export declare const searchRecentsIdb: IDB<string, SearchRecent, SearchRecent>;
|
|
34
|
+
/** Db of stored user alerts */
|
|
35
|
+
export declare const userAlertsIdb: IDB<string, AlertResponse, AlertRequest>;
|
|
36
|
+
/** Db of stored notams marked as read */
|
|
37
|
+
export declare const markedNotamsIdb: IDB<`${string}_${string}/${string}`, MarkedNotams, MarkedNotams>;
|
|
38
|
+
/** Latest used minifests */
|
|
39
|
+
export declare const minifestsIdb: IDB<string, MinifestObject, MinifestObject>;
|
|
40
|
+
/** Seen articles */
|
|
41
|
+
export declare const seenArticlesIdb: IDB<string, SeenArticle, SeenArticle>;
|
|
42
|
+
/** Seen promos */
|
|
43
|
+
export declare const seenPromosIdb: IDB<string, PromoInfoObject, PromoInfoObject>;
|
|
44
|
+
/** Custom user colors */
|
|
45
|
+
export declare const customColorsIdb: IDB<AnyColorIdent, UserColor, UserColor>;
|
package/types/client/layers.d.ts
CHANGED
|
@@ -54,6 +54,7 @@ declare const layers: {
|
|
|
54
54
|
dustsm: Layer<NumberedMetric>;
|
|
55
55
|
radar: Layer<NumberedMetric>;
|
|
56
56
|
satellite: Layer<NumberedMetric>;
|
|
57
|
+
radarPlus: Layer<NumberedMetric>;
|
|
57
58
|
gtco3: Layer<NumberedMetric>;
|
|
58
59
|
pm2p5: Layer<NumberedMetric>;
|
|
59
60
|
no2: Layer<NumberedMetric>;
|
|
@@ -74,5 +75,6 @@ declare const layers: {
|
|
|
74
75
|
dfm10h: Layer<NumberedMetric>;
|
|
75
76
|
turbulence: Layer<NumberedMetric>;
|
|
76
77
|
icing: Layer<NumberedMetric>;
|
|
78
|
+
topoMap: Layer<undefined>;
|
|
77
79
|
};
|
|
78
80
|
export default layers;
|
package/types/client/lib.d.ts
CHANGED
|
@@ -39,14 +39,12 @@ export * as detectDevice from '../services/detectDevice';
|
|
|
39
39
|
export * as device from '../services/device';
|
|
40
40
|
export * as deviceLogging from '../services/deviceLogging';
|
|
41
41
|
export * as geolocation from '../services/geolocation';
|
|
42
|
-
export
|
|
42
|
+
export * as notifications from '../services/notifications';
|
|
43
43
|
export * as ogTags from '../services/ogTags';
|
|
44
44
|
export * as params from '../services/params';
|
|
45
45
|
export * as rootScope from '../services/rootScope';
|
|
46
|
-
export * as showableErrorsService from '../services/showableErrorsService';
|
|
47
46
|
export { default as store } from '../services/store';
|
|
48
47
|
export * as trans from '../services/trans';
|
|
49
|
-
export * as BottomTagPlugin from '../pluginSystem/BottomTagPlugin';
|
|
50
48
|
export * as Plugin from '../pluginSystem/Plugin';
|
|
51
49
|
export * as SveltePanePlugin from '../pluginSystem/SveltePanePlugin';
|
|
52
50
|
export * as SveltePlugin from '../pluginSystem/SveltePlugin';
|
|
@@ -54,22 +52,10 @@ export * as TagPlugin from '../pluginSystem/TagPlugin';
|
|
|
54
52
|
export * as WindowPlugin from '../pluginSystem/WindowPlugin';
|
|
55
53
|
export { default as plugins } from '../pluginSystem/plugins';
|
|
56
54
|
export * as pluginsCtrl from '../pluginSystem/pluginsCtrl';
|
|
57
|
-
export * as Bar from '../uiClasses/Bar';
|
|
58
|
-
export * as BindedBar from '../uiClasses/BindedBar';
|
|
59
|
-
export * as BindedCheckbox from '../uiClasses/BindedCheckbox';
|
|
60
|
-
export * as BindedSwitch from '../uiClasses/BindedSwitch';
|
|
61
55
|
export * as BottomSlide from '../uiClasses/BottomSlide';
|
|
62
56
|
export * as ClickHandler from '../uiClasses/ClickHandler';
|
|
63
57
|
export * as Drag from '../uiClasses/Drag';
|
|
64
|
-
export * as DraggableDiv from '../uiClasses/DraggableDiv';
|
|
65
|
-
export * as GhostBox from '../uiClasses/GhostBox';
|
|
66
|
-
export * as LongTap from '../uiClasses/LongTap';
|
|
67
|
-
export * as MobileCalendar from '../uiClasses/MobileCalendar';
|
|
68
|
-
export * as ProductSwitch from '../uiClasses/ProductSwitch';
|
|
69
|
-
export * as Scrollable from '../uiClasses/Scrollable';
|
|
70
58
|
export * as Swipe from '../uiClasses/Swipe';
|
|
71
|
-
export * as Switch from '../uiClasses/Switch';
|
|
72
|
-
export * as TimestampBar from '../uiClasses/TimestampBar';
|
|
73
59
|
export * as Window from '../uiClasses/Window';
|
|
74
60
|
export * as rhMessage from '../ui/rhMessage';
|
|
75
61
|
export * as timeAnimation from '../ui/timeAnimation';
|
|
@@ -90,19 +76,19 @@ export { default as glTileRender } from '../render/glTileRender';
|
|
|
90
76
|
export * as renderTile from '../render/renderTile';
|
|
91
77
|
export * as tileLayer from '../render/tileLayerInstance';
|
|
92
78
|
export { default as GlObj } from '../wgUtils/GlObj';
|
|
93
|
-
export * as Favs from '../mapClasses/Favs';
|
|
94
79
|
export { default as LabelsLayer } from '../mapClasses/LabelsLayer';
|
|
95
80
|
export { default as LandMask } from '../mapClasses/LandMask';
|
|
96
81
|
export { default as TileLayerMultiPatch } from '../mapClasses/TileLayerMultiPatch';
|
|
97
|
-
export
|
|
82
|
+
export * as cityLabels from '../map/cityLabels';
|
|
98
83
|
export * as map from '../map/map';
|
|
99
84
|
export * as mapGlobeCtrl from '../map/mapGlobeCtrl';
|
|
100
85
|
export * as picker from '../map/picker';
|
|
101
86
|
export * as singleclick from '../map/singleclick';
|
|
102
|
-
export
|
|
103
|
-
export * as location from '../dummyModules/location';
|
|
104
|
-
export { default as log } from '../dummyModules/log';
|
|
87
|
+
export * as log from '../dummyModules/log';
|
|
105
88
|
export { default as promo } from '../dummyModules/promo';
|
|
106
|
-
export * as router from '../dummyModules/router';
|
|
107
89
|
export { default as seoParser } from '../dummyModules/seoParser';
|
|
90
|
+
export * as location from '../dummyModules/location';
|
|
91
|
+
export * as router from '../dummyModules/router';
|
|
92
|
+
export * as showableErrorsService from '../dummyModules/showableErrorsService';
|
|
93
|
+
export * as userFavs from '../dummyModules/userFavs';
|
|
108
94
|
export { default as libHtml } from '../lib/libHtml';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const loadArticlesOrWhatsNew: () => Promise<void>;
|
package/types/client/log.d.ts
CHANGED
|
@@ -65,5 +65,11 @@ declare class LRUCache<T = unknown> {
|
|
|
65
65
|
* Removes all entries
|
|
66
66
|
*/
|
|
67
67
|
removeAll(): void;
|
|
68
|
+
/**
|
|
69
|
+
* @summary Applies given callback to each element in the cache
|
|
70
|
+
* - call order is ASC in terms of record age (from oldest to newest)
|
|
71
|
+
* @param callback Callback to call for each element
|
|
72
|
+
*/
|
|
73
|
+
forEach(callback: (val: T, key: string) => void): void;
|
|
68
74
|
}
|
|
69
75
|
export default LRUCache;
|
package/types/client/map.d.ts
CHANGED
|
@@ -12,6 +12,7 @@
|
|
|
12
12
|
*/
|
|
13
13
|
import type { LatLon } from '@windy/interfaces.d';
|
|
14
14
|
import type { Pixel } from '@windy/types';
|
|
15
|
+
import type { MapLibreMap } from 'plugins/_shared/maplibre/mapLibreMap';
|
|
15
16
|
/**
|
|
16
17
|
* Already initialized instance of Leaflet L.Map
|
|
17
18
|
*
|
|
@@ -50,6 +51,7 @@ export declare const markers: Record<string, L.DivIcon>;
|
|
|
50
51
|
export interface CenterOptions extends LatLon {
|
|
51
52
|
zoom?: number;
|
|
52
53
|
paddingTop?: number;
|
|
54
|
+
paddingLeft?: number;
|
|
53
55
|
}
|
|
54
56
|
/**
|
|
55
57
|
* Centers/zooms leaflet map with optional offset to the left or top
|
|
@@ -57,7 +59,7 @@ export interface CenterOptions extends LatLon {
|
|
|
57
59
|
*/
|
|
58
60
|
export declare function centerMap(coords: CenterOptions, animation?: boolean): void;
|
|
59
61
|
/**
|
|
60
|
-
* Makes sure point is visible from bottom of the pane (will be
|
|
62
|
+
* Makes sure point is visible from bottom of the pane (will be deprecated)
|
|
61
63
|
* @ignore
|
|
62
64
|
*/
|
|
63
65
|
export declare function ensurePointVisibleY(lat: number, lon: number, offset: number): void;
|
|
@@ -67,14 +69,23 @@ export declare function ensurePointVisibleY(lat: number, lon: number, offset: nu
|
|
|
67
69
|
* @ignore
|
|
68
70
|
*/
|
|
69
71
|
export declare function panToOffset(y: Pixel, lat: number, lon: number): void;
|
|
70
|
-
/**
|
|
71
|
-
* Changes base map of underlying Windy.com map.
|
|
72
|
-
* @ignore
|
|
73
|
-
*/
|
|
74
|
-
export declare const baseLayer: L.GridLayer;
|
|
75
72
|
/**
|
|
76
73
|
* Retrieves the map tiles from the mapTilesRecord.
|
|
77
74
|
* @ignore
|
|
78
75
|
* @returns The map tiles.
|
|
79
76
|
*/
|
|
80
77
|
export declare const getMapTiles: (patchType?: string) => Record<import("@windy/baseMap").MapTilesKeys, string>;
|
|
78
|
+
/**
|
|
79
|
+
* Following object (singleton) contains all the stuff required for
|
|
80
|
+
* integration of mapLibre Gl into the client.
|
|
81
|
+
*/
|
|
82
|
+
export declare const mapLibre: {
|
|
83
|
+
/**
|
|
84
|
+
* Instance of our own mapLibre map wrapper Class
|
|
85
|
+
*/
|
|
86
|
+
wrapper: MapLibreMap | null;
|
|
87
|
+
};
|
|
88
|
+
/**
|
|
89
|
+
* Just handy shortcut to detect that globe is active
|
|
90
|
+
*/
|
|
91
|
+
export declare const isGlobeActive: () => boolean;
|
package/types/client/mobile.d.ts
CHANGED
|
@@ -9,6 +9,21 @@
|
|
|
9
9
|
* and modules consumed by plugins, MUST be listed here.
|
|
10
10
|
*/
|
|
11
11
|
export * as errorLogger from './utils/errorLogger';
|
|
12
|
+
/**
|
|
13
|
+
const originalGetCurrentPosition = navigator.geolocation.getCurrentPosition;
|
|
14
|
+
navigator.geolocation.getCurrentPosition = (...args) => {
|
|
15
|
+
alert(`XXX getCurrentPosition ${new Error().stack}`);
|
|
16
|
+
debugger;
|
|
17
|
+
originalGetCurrentPosition.call(navigator.geolocation, ...args);
|
|
18
|
+
};
|
|
19
|
+
// Monkey-patch watchPosition
|
|
20
|
+
const originalWatchPosition = navigator.geolocation.watchPosition;
|
|
21
|
+
navigator.geolocation.watchPosition = (...args) => {
|
|
22
|
+
alert('XXX watchPosition');
|
|
23
|
+
debugger;
|
|
24
|
+
return originalWatchPosition.call(navigator.geolocation, ...args);
|
|
25
|
+
};
|
|
26
|
+
*/
|
|
12
27
|
import './leafletExt/CanvasLayer';
|
|
13
28
|
export * as Evented from './utils/Evented';
|
|
14
29
|
export * as css from './utils/css';
|
|
@@ -21,6 +36,8 @@ export { default as lruCache } from './utils/lruCache';
|
|
|
21
36
|
export { default as storage } from './utils/storage';
|
|
22
37
|
export * as subscription from './utils/subscription';
|
|
23
38
|
export * as utils from './utils/utils';
|
|
39
|
+
export * as IDB from './utils/IDB';
|
|
40
|
+
export * as idbInstances from './utils/idbInstances';
|
|
24
41
|
export * as Calendar from './weatherClasses/Calendar';
|
|
25
42
|
export * as Color from './weatherClasses/Color';
|
|
26
43
|
export * as EcmwfAnalysisProduct from './weatherClasses/EcmwfAnalysisProduct';
|
|
@@ -51,19 +68,19 @@ export * as detectDevice from './services/detectDevice';
|
|
|
51
68
|
export * as device from './services/device';
|
|
52
69
|
export * as deviceLogging from './services/deviceLogging';
|
|
53
70
|
export * as geolocation from './services/geolocation';
|
|
54
|
-
export
|
|
55
|
-
export * as offlineController from './services/offlineController';
|
|
71
|
+
export * as notifications from './services/notifications';
|
|
56
72
|
export * as ogTags from './services/ogTags';
|
|
57
73
|
export * as params from './services/params';
|
|
58
74
|
export * as pois from './services/pois';
|
|
59
75
|
export * as reverseName from './services/reverseName';
|
|
60
76
|
export * as rootScope from './services/rootScope';
|
|
61
77
|
export * as router from './services/router';
|
|
62
|
-
export * as showableErrorsService from './services/showableErrorsService';
|
|
63
78
|
export { default as store } from './services/store';
|
|
64
79
|
export * as trans from './services/trans';
|
|
65
|
-
export
|
|
66
|
-
export * as
|
|
80
|
+
export * as userFavs from './services/userFavs';
|
|
81
|
+
export * as userAlerts from './services/userAlerts';
|
|
82
|
+
export * as userConsent from './services/userConsent';
|
|
83
|
+
export * as user from './services/user';
|
|
67
84
|
export * as Plugin from './pluginSystem/Plugin';
|
|
68
85
|
export * as SveltePanePlugin from './pluginSystem/SveltePanePlugin';
|
|
69
86
|
export * as SveltePlugin from './pluginSystem/SveltePlugin';
|
|
@@ -73,22 +90,10 @@ export * as WindowPlugin from './pluginSystem/WindowPlugin';
|
|
|
73
90
|
export { default as plugins } from './pluginSystem/plugins';
|
|
74
91
|
export * as pluginsCtrl from './pluginSystem/pluginsCtrl';
|
|
75
92
|
export * as externalPlugins from './pluginSystem/externalPlugins';
|
|
76
|
-
export * as Bar from './uiClasses/Bar';
|
|
77
|
-
export * as BindedBar from './uiClasses/BindedBar';
|
|
78
|
-
export * as BindedCheckbox from './uiClasses/BindedCheckbox';
|
|
79
|
-
export * as BindedSwitch from './uiClasses/BindedSwitch';
|
|
80
93
|
export * as BottomSlide from './uiClasses/BottomSlide';
|
|
81
94
|
export * as ClickHandler from './uiClasses/ClickHandler';
|
|
82
95
|
export * as Drag from './uiClasses/Drag';
|
|
83
|
-
export * as DraggableDiv from './uiClasses/DraggableDiv';
|
|
84
|
-
export * as GhostBox from './uiClasses/GhostBox';
|
|
85
|
-
export * as LongTap from './uiClasses/LongTap';
|
|
86
|
-
export * as MobileCalendar from './uiClasses/MobileCalendar';
|
|
87
|
-
export * as ProductSwitch from './uiClasses/ProductSwitch';
|
|
88
|
-
export * as Scrollable from './uiClasses/Scrollable';
|
|
89
96
|
export * as Swipe from './uiClasses/Swipe';
|
|
90
|
-
export * as Switch from './uiClasses/Switch';
|
|
91
|
-
export * as TimestampBar from './uiClasses/TimestampBar';
|
|
92
97
|
export * as Window from './uiClasses/Window';
|
|
93
98
|
export * as components from './ui/components';
|
|
94
99
|
export * as startupWeather from './ui/startupWeather';
|
|
@@ -99,9 +104,9 @@ export * as promo from './ui/promo';
|
|
|
99
104
|
export * as query from './ui/query';
|
|
100
105
|
export * as rhMessage from './ui/rhMessage';
|
|
101
106
|
export * as timeAnimation from './ui/timeAnimation';
|
|
102
|
-
export * as user from './ui/user';
|
|
103
107
|
export * as visibility from './ui/visibility';
|
|
104
108
|
export * as share from './ui/share';
|
|
109
|
+
export * as loadArticlesOrWhatsNew from './ui/loadArticlesOrWhatsNew';
|
|
105
110
|
export * as DataTiler from './renderClasses/DataTiler';
|
|
106
111
|
export * as Particles from './renderClasses/Particles';
|
|
107
112
|
export * as Renderer from './renderClasses/Renderer';
|
|
@@ -118,12 +123,11 @@ export { default as glTileRender } from './render/glTileRender';
|
|
|
118
123
|
export * as renderTile from './render/renderTile';
|
|
119
124
|
export * as tileLayer from './render/tileLayerInstance';
|
|
120
125
|
export { default as GlObj } from './wgUtils/GlObj';
|
|
121
|
-
export * as Favs from './mapClasses/Favs';
|
|
122
126
|
export { default as LabelsLayer } from './mapClasses/LabelsLayer';
|
|
123
127
|
export { default as LandMask } from './mapClasses/LandMask';
|
|
124
128
|
export { default as TileLayerMultiPatch } from './mapClasses/TileLayerMultiPatch';
|
|
125
129
|
export * as baseMap from './map/baseMap';
|
|
126
|
-
export
|
|
130
|
+
export * as cityLabels from './map/cityLabels';
|
|
127
131
|
export * as map from './map/map';
|
|
128
132
|
export * as mapGlobeCtrl from './map/mapGlobeCtrl';
|
|
129
133
|
export * as picker from './map/picker';
|
|
@@ -132,5 +136,9 @@ export * as mobile from './capacitor/mobile';
|
|
|
132
136
|
export * as mobileUtils from './capacitor/mobileUtils';
|
|
133
137
|
export * as nativeStorage from './capacitor/nativeStorage';
|
|
134
138
|
export * as pushNotifications from './capacitor/pushNotifications';
|
|
139
|
+
export * as appsFlyer from './capacitor/appsFlyer';
|
|
140
|
+
export * as showableErrorsService from './capacitor/showableErrorsService';
|
|
135
141
|
export * as seoParser from './dummyModules/seoParser';
|
|
136
142
|
import './ui/patchAndPromoCtrl';
|
|
143
|
+
import './ui/storeLastPosition';
|
|
144
|
+
import './services/customColors';
|
package/types/client/models.d.ts
CHANGED
|
@@ -26,7 +26,7 @@ export declare const getIconModel: (rqrdProduct: Products, avProducts: Products[
|
|
|
26
26
|
/**
|
|
27
27
|
* Return idents of visible local products available in the current map boundaries (or empty array undefined)
|
|
28
28
|
*/
|
|
29
|
-
export declare const betterProducts: <T extends LatLon, PT extends boolean, R extends PT extends true ? "icon" | "
|
|
29
|
+
export declare const betterProducts: <T extends LatLon, PT extends boolean, R extends PT extends true ? "icon" | "namConus" | "namHawaii" | "namAlaska" | "iconEu" | "iconD2" | "arome" | "aromeAntilles" | "aromeFrance" | "aromeReunion" | "canHrdps" | "canRdwpsWaves" | "czeAladin" | "iconEuWaves" | "hrrrAlaska" | "hrrrConus" | "bomAccess" | "bomAccessAd" | "bomAccessBn" | "bomAccessDn" | "bomAccessNq" | "bomAccessPh" | "bomAccessSy" | "bomAccessVt" | "ukv" | "jmaMsm" | "jmaCwmWaves" | "gfs" | "ecmwf" | "mblue" : "icon" | "radar" | "satellite" | "radarPlus" | "capAlerts" | "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" | "gfs" | "ecmwf" | "ecmwfAnalysis" | "ecmwfWaves" | "gfsWaves" | "cams" | "efi" | "cmems" | "drought" | "fireDanger" | "activeFires" | "mblue">(latLon: T, pointFcts?: PT) => R[];
|
|
30
30
|
/**
|
|
31
31
|
* Return product string on a basis of overlay & wanted forecast model
|
|
32
32
|
*/
|