@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.
Files changed (83) hide show
  1. package/README.md +1 -0
  2. package/package.json +1 -1
  3. package/types/client/Calendar.d.ts +101 -71
  4. package/types/client/Color.d.ts +18 -5
  5. package/types/client/DataTiler.d.ts +1 -1
  6. package/types/client/EcmwfProduct.d.ts +22 -0
  7. package/types/client/IDB.d.ts +1 -1
  8. package/types/client/Layer.d.ts +95 -26
  9. package/types/client/LayerClasses.d.ts +5 -0
  10. package/types/client/Metric.d.ts +31 -46
  11. package/types/client/Overlay.d.ts +8 -11
  12. package/types/client/OverlayClasses.d.ts +8 -0
  13. package/types/client/Particles.d.ts +1 -1
  14. package/types/client/Product.d.ts +31 -65
  15. package/types/client/ProductClasses.d.ts +44 -0
  16. package/types/client/RadarPlusProduct.d.ts +1 -1
  17. package/types/client/Renderer.d.ts +41 -13
  18. package/types/client/SatelliteProduct.d.ts +1 -1
  19. package/types/client/SveltePlugin.d.ts +1 -1
  20. package/types/client/TileLayer.d.ts +2 -2
  21. package/types/client/TopoMap.d.ts +2 -3
  22. package/types/client/WindowPlugin.d.ts +6 -3
  23. package/types/client/appsFlyer.d.ts +2 -1
  24. package/types/client/colorGradients.d.ts +5 -10
  25. package/types/client/colors.d.ts +1 -2
  26. package/types/client/d.ts.files/Metric.d.ts +21 -2
  27. package/types/client/d.ts.files/TileLayerCanvas.d.ts +3 -3
  28. package/types/client/d.ts.files/alerts.d.ts +1 -0
  29. package/types/client/d.ts.files/broadcast.d.ts +3 -3
  30. package/types/client/d.ts.files/dataSpecifications.d.ts +32 -34
  31. package/types/client/d.ts.files/favs.d.ts +7 -18
  32. package/types/client/d.ts.files/http.d.ts +5 -0
  33. package/types/client/d.ts.files/lib.d.ts +0 -1
  34. package/types/client/d.ts.files/plugin-params.d.ts +20 -16
  35. package/types/client/d.ts.files/plugins.d.ts +0 -2
  36. package/types/client/d.ts.files/rootScope.d.ts +2 -0
  37. package/types/client/d.ts.files/webcams.d.ts +9 -2
  38. package/types/client/dataLoader.d.ts +2 -2
  39. package/types/client/detectDevice.d.ts +3 -0
  40. package/types/client/embed.d.ts +0 -2
  41. package/types/client/errorLogger.d.ts +1 -1
  42. package/types/client/externalPlugins.d.ts +2 -0
  43. package/types/client/fetch.d.ts +28 -4
  44. package/types/client/format.d.ts +1 -0
  45. package/types/client/glTileRender.d.ts +1 -7
  46. package/types/client/idbInstances.d.ts +115 -4
  47. package/types/client/layers.d.ts +3 -1
  48. package/types/client/legends.d.ts +1 -1
  49. package/types/client/lib.d.ts +0 -7
  50. package/types/client/map.d.ts +7 -1
  51. package/types/client/mobile.d.ts +0 -7
  52. package/types/client/models.d.ts +2 -6
  53. package/types/client/overlays.d.ts +2 -1
  54. package/types/client/particleRenderers.d.ts +1 -1
  55. package/types/client/plugins.d.ts +0 -4
  56. package/types/client/products.d.ts +54 -2
  57. package/types/client/promo.d.ts +28 -5
  58. package/types/client/pushNotifications.d.ts +19 -1
  59. package/types/client/renderCtrl.d.ts +1 -1
  60. package/types/client/renderTile.d.ts +2 -2
  61. package/types/client/renderUtils.d.ts +16 -36
  62. package/types/client/renderers.d.ts +2 -4
  63. package/types/client/reverseName.d.ts +2 -1
  64. package/types/client/rhMessage.d.ts +1 -1
  65. package/types/client/rootScope.d.ts +14 -6
  66. package/types/client/router.d.ts +36 -9
  67. package/types/client/seoParser.d.ts +35 -0
  68. package/types/client/showableErrorsService.d.ts +10 -6
  69. package/types/client/store.d.ts +20 -52
  70. package/types/client/tileInterpolator.d.ts +1 -1
  71. package/types/client/userAlerts.d.ts +0 -4
  72. package/types/client/userFavs.d.ts +23 -10
  73. package/types/client/utils.d.ts +18 -17
  74. package/types/interfaces.d.ts +197 -16
  75. package/types/lang-files.d.ts +167 -27
  76. package/types/types.d.ts +297 -7
  77. package/types/client/d.ts.files/Calendar.d.ts +0 -96
  78. package/types/client/d.ts.files/Color.d.ts +0 -94
  79. package/types/client/d.ts.files/Layer.d.ts +0 -191
  80. package/types/client/d.ts.files/Renderer.d.ts +0 -44
  81. package/types/client/d.ts.files/products.d.ts +0 -60
  82. package/types/client/imaker.d.ts +0 -112
  83. package/types/offline.d.ts +0 -100
@@ -1,7 +1,6 @@
1
1
  import { IDB } from '@windy/IDB';
2
2
  import type { MarkedNotams } from '@plugins/airport/airport';
3
- import type { SearchRecent } from '@plugins/search/search';
4
- import type { AnyColorIdent, UserColor } from '@windy/Color.d';
3
+ import type { AnyColorIdent, UserColor } from '@windy/Color';
5
4
  import type { AlertRequest, AlertResponse } from '@windy/alerts';
6
5
  import type { Fav, FavFragment } from '@windy/favs.d';
7
6
  import type { CapAlertSlided, InstalledExternalPluginConfig } from '@windy/interfaces';
@@ -10,7 +9,119 @@ import type { SeenArticle, SeenStory } from '@windy/startup.d';
10
9
  export declare const initPromise: Promise<IDBDatabase>;
11
10
  /** Db of stored user favourites */
12
11
  export declare const userFavsIdb: IDB<string, Fav, FavFragment>;
13
- export declare const searchRecentsIdb: IDB<string, SearchRecent, SearchRecent>;
12
+ export declare const searchRecentsIdb: IDB<string, (import("@plugins/search/search").SearchRecentItem & import("@plugins/search/search").RequiredSearchItemProperties & {
13
+ type: "windy-overlay";
14
+ ident: "visibility" | "radar" | "satellite" | "radarPlus" | "wind" | "gust" | "gustAccu" | "turbulence" | "icing" | "rain" | "rainAccu" | "snowAccu" | "snowcover" | "ptype" | "thunder" | "temp" | "dewpoint" | "rh" | "deg0" | "wetbulbtemp" | "solarpower" | "uvindex" | "clouds" | "hclouds" | "mclouds" | "lclouds" | "fog" | "cloudtop" | "cbase" | "cape" | "ccl" | "waves" | "swell1" | "swell2" | "swell3" | "wwaves" | "sst" | "currents" | "currentsTide" | "aqi" | "no2" | "pm2p5" | "aod550" | "gtco3" | "tcso2" | "go3" | "cosc" | "dustsm" | "pressure" | "efiTemp" | "efiWind" | "efiRain" | "capAlerts" | "soilMoisture40" | "soilMoisture100" | "moistureAnom40" | "moistureAnom100" | "drought40" | "drought100" | "fwi" | "dfm10h" | "heatmaps" | "topoMap" | "hurricanes";
15
+ thumbnailUrl: string;
16
+ noValidLocation: true;
17
+ addShakyClass: true;
18
+ doNotSave: true;
19
+ }) | (import("@plugins/search/search").SearchRecentItem & import("@plugins/search/search").RequiredSearchItemProperties & {
20
+ type: "windy-poi";
21
+ ident: string;
22
+ poiIcon: import("../../types/iconfont").Iconfont;
23
+ noValidLocation: true;
24
+ addShakyClass: true;
25
+ doNotSave: true;
26
+ }) | (import("@plugins/search/search").SearchRecentItem & import("@plugins/search/search").RequiredSearchItemProperties & import("@windy/interfaces").LatLon & import("@plugins/search/search").CountryAndRegionInformation & {
27
+ type: "airport";
28
+ icao: string;
29
+ iata?: string;
30
+ }) | (import("@plugins/search/search").SearchRecentItem & import("@plugins/search/search").RequiredSearchItemProperties & import("@windy/interfaces").LatLon & import("@plugins/search/search").CountryAndRegionInformation & {
31
+ type: "heliport";
32
+ icao: string;
33
+ iata?: string;
34
+ }) | (import("@plugins/search/search").SearchRecentItem & import("@plugins/search/search").RequiredSearchItemProperties & import("@windy/interfaces").LatLon & import("@plugins/search/search").CountryAndRegionInformation & {
35
+ type: "station";
36
+ stationId: `radiation-${string}` | `airq-${string}` | `ad-${string}` | `wmo-${string}` | `madis-${string}` | `buoy-${string}` | `dbuoy-${string}` | `pws-${string}` | `ship-${string}`;
37
+ }) | (import("@plugins/search/search").SearchRecentItem & import("@plugins/search/search").RequiredSearchItemProperties & import("@windy/interfaces").LatLon & import("@plugins/search/search").CountryAndRegionInformation & {
38
+ type: "webcam";
39
+ webcamId: number;
40
+ }) | (import("@plugins/search/search").SearchRecentItem & import("@plugins/search/search").RequiredSearchItemProperties & import("@windy/interfaces").LatLon & import("@plugins/search/search").CountryAndRegionInformation & {
41
+ type: "radiosonde";
42
+ id: string;
43
+ }) | (import("@plugins/search/search").SearchRecentItem & import("@plugins/search/search").RequiredSearchItemProperties & import("@windy/interfaces").LatLon & import("@plugins/search/search").CountryAndRegionInformation & {
44
+ type: import("@plugins/search/search").StandardSearchType;
45
+ }) | (import("@plugins/search/search").SearchRecentItem & import("@plugins/search/search").RequiredSearchItemProperties & import("@windy/interfaces").LatLon & {
46
+ type: "hurricane";
47
+ strength: import("../../plugins/_shared/hurricanes/types").StormStrength;
48
+ stormId: string;
49
+ addShakyClass: true;
50
+ doNotSave: true;
51
+ }) | (import("@plugins/search/search").SearchRecentItem & import("@plugins/search/search").RequiredSearchItemProperties & import("@windy/interfaces").LatLon & {
52
+ type: "route";
53
+ fromTo: [import("@plugins/search/search").AirportSearchResult, import("@plugins/search/search").AirportSearchResult];
54
+ distance: number;
55
+ }) | (import("@plugins/search/search").SearchRecentItem & import("@windy/interfaces").LatLon & {
56
+ title: string;
57
+ cc?: import("@windy/types").ISOCountryCode | "xx";
58
+ } & {
59
+ type: "fav";
60
+ } & {
61
+ id: string;
62
+ pin2top?: number;
63
+ pin2homepage?: number;
64
+ updated: number;
65
+ } & import("@plugins/search/search").CountryAndRegionInformation & {
66
+ noValidLocation?: false;
67
+ type: "fav";
68
+ }), (import("@plugins/search/search").SearchRecentItem & import("@plugins/search/search").RequiredSearchItemProperties & {
69
+ type: "windy-overlay";
70
+ ident: "visibility" | "radar" | "satellite" | "radarPlus" | "wind" | "gust" | "gustAccu" | "turbulence" | "icing" | "rain" | "rainAccu" | "snowAccu" | "snowcover" | "ptype" | "thunder" | "temp" | "dewpoint" | "rh" | "deg0" | "wetbulbtemp" | "solarpower" | "uvindex" | "clouds" | "hclouds" | "mclouds" | "lclouds" | "fog" | "cloudtop" | "cbase" | "cape" | "ccl" | "waves" | "swell1" | "swell2" | "swell3" | "wwaves" | "sst" | "currents" | "currentsTide" | "aqi" | "no2" | "pm2p5" | "aod550" | "gtco3" | "tcso2" | "go3" | "cosc" | "dustsm" | "pressure" | "efiTemp" | "efiWind" | "efiRain" | "capAlerts" | "soilMoisture40" | "soilMoisture100" | "moistureAnom40" | "moistureAnom100" | "drought40" | "drought100" | "fwi" | "dfm10h" | "heatmaps" | "topoMap" | "hurricanes";
71
+ thumbnailUrl: string;
72
+ noValidLocation: true;
73
+ addShakyClass: true;
74
+ doNotSave: true;
75
+ }) | (import("@plugins/search/search").SearchRecentItem & import("@plugins/search/search").RequiredSearchItemProperties & {
76
+ type: "windy-poi";
77
+ ident: string;
78
+ poiIcon: import("../../types/iconfont").Iconfont;
79
+ noValidLocation: true;
80
+ addShakyClass: true;
81
+ doNotSave: true;
82
+ }) | (import("@plugins/search/search").SearchRecentItem & import("@plugins/search/search").RequiredSearchItemProperties & import("@windy/interfaces").LatLon & import("@plugins/search/search").CountryAndRegionInformation & {
83
+ type: "airport";
84
+ icao: string;
85
+ iata?: string;
86
+ }) | (import("@plugins/search/search").SearchRecentItem & import("@plugins/search/search").RequiredSearchItemProperties & import("@windy/interfaces").LatLon & import("@plugins/search/search").CountryAndRegionInformation & {
87
+ type: "heliport";
88
+ icao: string;
89
+ iata?: string;
90
+ }) | (import("@plugins/search/search").SearchRecentItem & import("@plugins/search/search").RequiredSearchItemProperties & import("@windy/interfaces").LatLon & import("@plugins/search/search").CountryAndRegionInformation & {
91
+ type: "station";
92
+ stationId: `radiation-${string}` | `airq-${string}` | `ad-${string}` | `wmo-${string}` | `madis-${string}` | `buoy-${string}` | `dbuoy-${string}` | `pws-${string}` | `ship-${string}`;
93
+ }) | (import("@plugins/search/search").SearchRecentItem & import("@plugins/search/search").RequiredSearchItemProperties & import("@windy/interfaces").LatLon & import("@plugins/search/search").CountryAndRegionInformation & {
94
+ type: "webcam";
95
+ webcamId: number;
96
+ }) | (import("@plugins/search/search").SearchRecentItem & import("@plugins/search/search").RequiredSearchItemProperties & import("@windy/interfaces").LatLon & import("@plugins/search/search").CountryAndRegionInformation & {
97
+ type: "radiosonde";
98
+ id: string;
99
+ }) | (import("@plugins/search/search").SearchRecentItem & import("@plugins/search/search").RequiredSearchItemProperties & import("@windy/interfaces").LatLon & import("@plugins/search/search").CountryAndRegionInformation & {
100
+ type: import("@plugins/search/search").StandardSearchType;
101
+ }) | (import("@plugins/search/search").SearchRecentItem & import("@plugins/search/search").RequiredSearchItemProperties & import("@windy/interfaces").LatLon & {
102
+ type: "hurricane";
103
+ strength: import("../../plugins/_shared/hurricanes/types").StormStrength;
104
+ stormId: string;
105
+ addShakyClass: true;
106
+ doNotSave: true;
107
+ }) | (import("@plugins/search/search").SearchRecentItem & import("@plugins/search/search").RequiredSearchItemProperties & import("@windy/interfaces").LatLon & {
108
+ type: "route";
109
+ fromTo: [import("@plugins/search/search").AirportSearchResult, import("@plugins/search/search").AirportSearchResult];
110
+ distance: number;
111
+ }) | (import("@plugins/search/search").SearchRecentItem & import("@windy/interfaces").LatLon & {
112
+ title: string;
113
+ cc?: import("@windy/types").ISOCountryCode | "xx";
114
+ } & {
115
+ type: "fav";
116
+ } & {
117
+ id: string;
118
+ pin2top?: number;
119
+ pin2homepage?: number;
120
+ updated: number;
121
+ } & import("@plugins/search/search").CountryAndRegionInformation & {
122
+ noValidLocation?: false;
123
+ type: "fav";
124
+ })>;
14
125
  /** Db of stored user alerts */
15
126
  export declare const userAlertsIdb: IDB<string, AlertResponse, AlertRequest>;
16
127
  /** Db of stored notams marked as read */
@@ -26,7 +137,7 @@ export declare const slidedCapAlertsIdb: IDB<string, CapAlertSlided, CapAlertSli
26
137
  /** Seen stories */
27
138
  export declare const seenStoriesIdb: IDB<string, SeenStory, SeenStory>;
28
139
  /** Log of pages & events that happened on this device */
29
- export declare const logIdb: IDB<`airport/${string}` | `articles/${string}` | `garmin/${string}` | `onboarding/${string}` | `station/${string}` | `subscription/${string}` | `pois/${string}` | `version/${string}` | `overlay/${string}` | `level/${string}` | `acRange/${string}` | `path/${string}` | `isolinesType/${string}` | `isolinesOn/${string}` | `product/${string}` | `plugin/${string}` | `startup/${string}` | `404/${string}` | `promo/${string}` | `appRating/${string}` | `appOpening/${string}` | `detail2/${string}` | `appsflyer/${string}` | `weather/${string}` | `events/${string}` | `locationPermissionPopup/${string}` | `widgetPromo/${string}` | `storyEvent/${string}`, number, number>;
140
+ export declare const logIdb: IDB<`plugin/${string}` | `version/${string}` | `pois/${string}` | `subscription/${string}` | `airport/${string}` | `station/${string}` | `garmin/${string}` | `onboarding/${string}` | `articles/${string}` | `isolinesType/${string}` | `overlay/${string}` | `level/${string}` | `product/${string}` | `acRange/${string}` | `isolinesOn/${string}` | `path/${string}` | `startup/${string}` | `404/${string}` | `promo/${string}` | `appRating/${string}` | `appOpening/${string}` | `detail2/${string}` | `appsflyer/${string}` | `weather/${string}` | `events/${string}` | `locationPermissionPopup/${string}` | `widgetPromo/${string}` | `storyEvent/${string}`, number, number>;
30
141
  /** Log of locations, that user uses on this device */
31
142
  export declare const popularLocationsIdb: IDB<string, number, number>;
32
143
  /** Seen stories */
@@ -1,4 +1,5 @@
1
- import { Layer, WaveLayer } from '@windy/Layer';
1
+ import { Layer } from '@windy/Layer';
2
+ import { WaveLayer } from '@windy/LayerClasses';
2
3
  import type { NumberedMetric, PrecipMetric, PtypeMetric } from '@windy/MetricClasses';
3
4
  declare const layers: {
4
5
  capAlerts: Layer<undefined>;
@@ -76,5 +77,6 @@ declare const layers: {
76
77
  turbulence: Layer<NumberedMetric>;
77
78
  icing: Layer<NumberedMetric>;
78
79
  topoMap: Layer<undefined>;
80
+ aqi: Layer<NumberedMetric>;
79
81
  };
80
82
  export default layers;
@@ -1,4 +1,4 @@
1
- import type { Layers } from '@windy/Layer.d';
1
+ import type { Layers } from '@windy/Layer';
2
2
  import type { Legend } from '@windy/Metric.d';
3
3
  declare const customLegends: {
4
4
  [P in Layers]?: Legend;
@@ -12,18 +12,12 @@ export * as subscription from '../utils/subscription';
12
12
  export * as utils from '../utils/utils';
13
13
  export * as Calendar from '../weatherClasses/Calendar';
14
14
  export * as Color from '../weatherClasses/Color';
15
- export * as EcmwfProduct from '../weatherClasses/EcmwfProduct';
16
- export * as HrrrProducts from '../weatherClasses/HrrrProducts';
17
- export * as IconProducts from '../weatherClasses/IconProducts';
18
15
  export * as Layer from '../weatherClasses/Layer';
19
16
  export * as Metric from '../weatherClasses/Metric';
20
17
  export * as MetricClasses from '../weatherClasses/MetricClasses';
21
- export * as NamProducts from '../weatherClasses/NamProducts';
22
18
  export * as Overlay from '../weatherClasses/Overlay';
23
19
  export * as OverlayClasses from '../weatherClasses/OverlayClasses';
24
20
  export * as Product from '../weatherClasses/Product';
25
- export * as SatelliteProduct from '../weatherClasses/SatelliteProduct';
26
- export * as StaticProduct from '../weatherClasses/StaticProduct';
27
21
  export { default as layers } from '../weather/layers';
28
22
  export { default as legends } from '../weather/legends';
29
23
  export { default as metrics } from '../weather/metrics';
@@ -52,7 +46,6 @@ export * as WindowPlugin from '../pluginSystem/WindowPlugin';
52
46
  export { default as plugins } from '../pluginSystem/plugins';
53
47
  export * as pluginsCtrl from '../pluginSystem/pluginsCtrl';
54
48
  export * as BottomSlide from '../uiClasses/BottomSlide';
55
- export * as ClickHandler from '../uiClasses/ClickHandler';
56
49
  export * as Drag from '../uiClasses/Drag';
57
50
  export * as Swipe from '../uiClasses/Swipe';
58
51
  export * as Window from '../uiClasses/Window';
@@ -10,7 +10,7 @@
10
10
  *
11
11
  * @module map
12
12
  */
13
- import type { LatLon } from '@windy/interfaces.d';
13
+ import type { LatLon, SimplifiedGetBoundsOptions } from '@windy/interfaces.d';
14
14
  import type { Pixel } from '@windy/types';
15
15
  import type { MapLibreMap } from 'plugins/_shared/maplibre/mapLibreMap';
16
16
  /**
@@ -69,6 +69,12 @@ export declare function ensurePointVisibleY(lat: number, lon: number, offset: nu
69
69
  * @ignore
70
70
  */
71
71
  export declare function panToOffset(y: Pixel, lat: number, lon: number): void;
72
+ /**
73
+ * fitBounds either in Leaflet or in mapLibre using [ W, S, E, N ] coordinates.
74
+ */
75
+ export declare function fitBounds(boundsArray: [number, number, number, number], options?: SimplifiedGetBoundsOptions): void;
76
+ export declare function toggleLandMask(landOnly: boolean): void;
77
+ export declare function toggleSeaMask(hasSea: boolean): void;
72
78
  /**
73
79
  * Retrieves the map tiles from the mapTilesRecord.
74
80
  * @ignore
@@ -41,18 +41,12 @@ export * as IDB from './utils/IDB';
41
41
  export * as idbInstances from './utils/idbInstances';
42
42
  export * as Calendar from './weatherClasses/Calendar';
43
43
  export * as Color from './weatherClasses/Color';
44
- export * as EcmwfProduct from './weatherClasses/EcmwfProduct';
45
- export * as HrrrProducts from './weatherClasses/HrrrProducts';
46
- export * as IconProducts from './weatherClasses/IconProducts';
47
44
  export * as Layer from './weatherClasses/Layer';
48
45
  export * as Metric from './weatherClasses/Metric';
49
46
  export * as MetricClasses from './weatherClasses/MetricClasses';
50
- export * as NamProducts from './weatherClasses/NamProducts';
51
47
  export * as Overlay from './weatherClasses/Overlay';
52
48
  export * as OverlayClasses from './weatherClasses/OverlayClasses';
53
49
  export * as Product from './weatherClasses/Product';
54
- export * as SatelliteProduct from './weatherClasses/SatelliteProduct';
55
- export * as StaticProduct from './weatherClasses/StaticProduct';
56
50
  export { default as layers } from './weather/layers';
57
51
  export { default as legends } from './weather/legends';
58
52
  export { default as metrics } from './weather/metrics';
@@ -92,7 +86,6 @@ export { default as plugins } from './pluginSystem/plugins';
92
86
  export * as pluginsCtrl from './pluginSystem/pluginsCtrl';
93
87
  export * as externalPlugins from './pluginSystem/externalPlugins';
94
88
  export * as BottomSlide from './uiClasses/BottomSlide';
95
- export * as ClickHandler from './uiClasses/ClickHandler';
96
89
  export * as Drag from './uiClasses/Drag';
97
90
  export * as Swipe from './uiClasses/Swipe';
98
91
  export * as Window from './uiClasses/Window';
@@ -1,4 +1,4 @@
1
- import type { Layers } from '@windy/Layer.d';
1
+ import type { Layers } from '@windy/Layer';
2
2
  import type { UsedOverlays } from '@windy/Overlay';
3
3
  import type { LatLon } from '@windy/interfaces.d';
4
4
  import type { Overlays, PointProducts, Products } from '@windy/rootScope.d';
@@ -15,10 +15,6 @@ export declare const layer2product: {
15
15
  export declare const overlay2product: {
16
16
  [P in LayerOrOverlay]?: Products[];
17
17
  };
18
- /**
19
- * From list of products deduplicates icon/iconEu, iconWaves/iconEuWaves
20
- */
21
- export declare const removeModelsFromSameGroup: (productsList: Products[]) => Products[];
22
18
  /**
23
19
  * Return particular icon related model based on rqrd and avbl models
24
20
  */
@@ -26,7 +22,7 @@ export declare const bestModelFromSameGroup: (rqrdProduct: Products, avProducts:
26
22
  /**
27
23
  * Return idents of visible local products available in the current map boundaries (or empty array undefined)
28
24
  */
29
- export declare const betterProducts: <T extends LatLon, PT extends boolean, R extends PT extends true ? "gfs" | "ecmwf" | "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" | "mblue" : "drought" | "radar" | "satellite" | "radarPlus" | "capAlerts" | "topoMap" | "gfs" | "ecmwf" | "ecmwfAnalysis" | "ecmwfWaves" | "gfsWaves" | "icon" | "cams" | "efi" | "cmems" | "fireDanger" | "activeFires" | "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" | "mblue">(latLon: T, pointFcts?: PT) => R[];
25
+ 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" | "camsEu" | "czeAladin" | "iconEuWaves" | "hrrrAlaska" | "hrrrConus" | "bomAccess" | "bomAccessAd" | "bomAccessBn" | "bomAccessDn" | "bomAccessNq" | "bomAccessPh" | "bomAccessSy" | "bomAccessVt" | "ukv" | "jmaMsm" | "jmaCwmWaves" | "gfs" | "ecmwf" | "cams" | "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
26
  /**
31
27
  * Return product string on a basis of overlay & wanted forecast model
32
28
  */
@@ -1,5 +1,5 @@
1
1
  import { Overlay } from '@windy/Overlay';
2
- import { AwpOverlay, CloudsOverlay, CurrentOverlay, FwiOverlay, RainPtypeOverlay, WaveOverlay } from '@windy/OverlayClasses';
2
+ import { AqiOverlay, AwpOverlay, CloudsOverlay, CurrentOverlay, FwiOverlay, RainPtypeOverlay, WaveOverlay } from '@windy/OverlayClasses';
3
3
  declare const overlays: {
4
4
  wind: Overlay<"wind", import("../weatherClasses/MetricClasses").NumberedMetric, import("../weatherClasses/Layer").Layer<import("../weatherClasses/MetricClasses").NumberedMetric>>;
5
5
  temp: Overlay<"temp", import("../weatherClasses/MetricClasses").NumberedMetric, import("../weatherClasses/Layer").Layer<import("../weatherClasses/MetricClasses").NumberedMetric>>;
@@ -66,5 +66,6 @@ declare const overlays: {
66
66
  heatmaps: Overlay<"heatmaps", undefined, undefined>;
67
67
  topoMap: Overlay<"topoMap", undefined, import("../weatherClasses/Layer").Layer<undefined>>;
68
68
  hurricanes: Overlay<"hurricanes", undefined, undefined>;
69
+ aqi: AqiOverlay<"aqi">;
69
70
  };
70
71
  export default overlays;
@@ -1,4 +1,4 @@
1
1
  import { Particles } from '@windy/Particles';
2
- import type { ParticlesIdent } from '@windy/Layer.d';
2
+ import type { ParticlesIdent } from '@windy/types';
3
3
  declare const particleRenderes: Record<ParticlesIdent, Particles>;
4
4
  export default particleRenderes;
@@ -1,7 +1,3 @@
1
1
  import type { Plugins } from './d.ts.files/plugins.d';
2
2
  declare const plugins: Plugins;
3
- /**
4
- * Promise resolves once installed external plugins have loaded into default export
5
- */
6
- export declare const externalPluginsLoaded: Promise<void>;
7
3
  export default plugins;
@@ -1,3 +1,55 @@
1
- import type { products as Iproducts } from './d.ts.files/products.d';
2
- declare const products: Iproducts;
1
+ import { Product } from '@windy/Product';
2
+ import { AromeProduct, AccessProduct, AccessCProduct, EcmwfForecastProduct, EcmwfProduct, SatAndRadarPlusProduct } from '@windy/ProductClasses';
3
+ import type { Products } from '@windy/rootScope.d';
4
+ type AllExportedProducts = Implements<{
5
+ [P in Products]: Product;
6
+ }, {
7
+ bomAccess: AccessProduct;
8
+ bomAccessAd: AccessCProduct;
9
+ bomAccessBn: AccessCProduct;
10
+ bomAccessDn: AccessCProduct;
11
+ bomAccessNq: AccessCProduct;
12
+ bomAccessPh: AccessCProduct;
13
+ bomAccessSy: AccessCProduct;
14
+ bomAccessVt: AccessCProduct;
15
+ mblue: Product;
16
+ ecmwf: EcmwfForecastProduct;
17
+ ecmwfWaves: Product;
18
+ ecmwfAnalysis: EcmwfProduct;
19
+ canHrdps: Product;
20
+ canRdwpsWaves: Product;
21
+ cams: Product;
22
+ camsEu: Product;
23
+ cmems: Product;
24
+ czeAladin: Product;
25
+ gfs: Product;
26
+ gfsWaves: Product;
27
+ icon: Product;
28
+ iconD2: Product;
29
+ iconEu: Product;
30
+ iconEuWaves: Product;
31
+ arome: Product;
32
+ aromeAntilles: AromeProduct;
33
+ aromeFrance: AromeProduct;
34
+ aromeReunion: AromeProduct;
35
+ nems: Product;
36
+ namAlaska: Product;
37
+ namConus: Product;
38
+ namHawaii: Product;
39
+ capAlerts: Product;
40
+ efi: Product;
41
+ radar: Product;
42
+ satellite: SatAndRadarPlusProduct;
43
+ radarPlus: SatAndRadarPlusProduct;
44
+ hrrrAlaska: Product;
45
+ hrrrConus: Product;
46
+ ukv: Product;
47
+ drought: Product;
48
+ fireDanger: Product;
49
+ activeFires: Product;
50
+ jmaMsm: Product;
51
+ jmaCwmWaves: Product;
52
+ topoMap: Product;
53
+ }>;
54
+ declare const products: AllExportedProducts;
3
55
  export default products;
@@ -1,21 +1,44 @@
1
- import type { Timestamp } from '@windy/types';
1
+ import type { ISODateString, Timestamp, TimeRangeMs } from '@windy/types';
2
+ type PromoUniqueId = string;
2
3
  export interface PromoInfoObject {
3
- id: string;
4
+ id: PromoUniqueId;
4
5
  displayed: number;
5
6
  ts: Timestamp;
6
7
  }
7
8
  /**
8
9
  * Get basic info about promo for given ident
9
10
  */
10
- export declare const getCounter: (id: string) => Promise<PromoInfoObject>;
11
+ export declare const getCounter: (id: PromoUniqueId) => Promise<PromoInfoObject>;
11
12
  /**
12
13
  * Increases 'seen' counter for particular promo
13
14
  */
14
- export declare const hitCounter: (id: string, logEvent?: boolean) => Promise<void>;
15
+ export declare const hitCounter: (id: PromoUniqueId, logEvent?: boolean) => Promise<void>;
15
16
  /**
16
17
  * Flag the promo to be never seen again (by setting
17
18
  * its number to 1000)
18
19
  *
19
20
  * @param ident Ident
20
21
  */
21
- export declare const neverSee: (ident: string) => void;
22
+ export declare const neverSee: (ident: PromoUniqueId) => void;
23
+ /**
24
+ * Determines if promo should be displayed or not
25
+ */
26
+ export declare const shouldDisplayPromo: ({ id, end, counter, delay, }: {
27
+ /**
28
+ * Main ID of the promo. This key is also used in `promo` object in localStorage
29
+ */
30
+ id: PromoUniqueId;
31
+ /**
32
+ * ISO date, when the promo expires
33
+ */
34
+ end?: ISODateString;
35
+ /**
36
+ * How many times display promo to the user (respective on one device)
37
+ */
38
+ counter: number;
39
+ /**
40
+ * How often to display promo on particular device (in ms)
41
+ */
42
+ delay: TimeRangeMs;
43
+ }) => Promise<boolean>;
44
+ export {};
@@ -1 +1,19 @@
1
- export declare const registerDevice: () => Promise<null>;
1
+ import type { LatLon } from '@windy/interfaces.d';
2
+ export interface NotificationExtraPayload extends LatLon {
3
+ /** Identifier of the process in node-notif */
4
+ processId: string;
5
+ id: string | undefined;
6
+ hrTimestamps: string;
7
+ icao?: string;
8
+ category: 'alert' | 'metar' | 'location';
9
+ notificationId?: string;
10
+ locationEntityId?: string;
11
+ }
12
+ export type RegistrationHash = string;
13
+ /**
14
+ * Ask for notif permissions if missing
15
+ *
16
+ * @returns null | registration Hash
17
+ */
18
+ export declare function requestPermissions(): Promise<RegistrationHash | null>;
19
+ export declare function registerDevice(): Promise<RegistrationHash | null>;
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * Major render controller
3
3
  *
4
- * @module renderCtrls
4
+ * @module renderCtrl
5
5
  *
6
6
  * LIMITATION: The system is not ready for situation of ongoing tasks, when new UI event start new tasks
7
7
  */
@@ -1,6 +1,6 @@
1
1
  import type { DataTile } from '@windy/dataLoader';
2
- import type { TileParams } from '@windy/Renderer.d';
2
+ import type { TileParams } from '@windy/Renderer';
3
3
  import type { TileLayerCanvas } from '@windy/TileLayerCanvas.d';
4
4
  declare const renderNoDataTile: (canvas: HTMLCanvasElement, url?: string) => void;
5
- declare const renderTile: (this: TileLayerCanvas, step: 1 | 2, canvas: HTMLCanvasElement, rqrdSyncNum: number, tInfo: TileParams, dTile: DataTile) => void;
5
+ declare const renderTile: (this: TileLayerCanvas, _step: 1 | 2, canvas: HTMLCanvasElement, rqrdSyncNum: number, tInfo: TileParams, dTile: DataTile) => void;
6
6
  export { renderNoDataTile, renderTile };
@@ -1,31 +1,23 @@
1
1
  /**
2
- * Shared rendering utilities (and also event emmiter for rendering purposes)
2
+ * Shared rendering utilities (and also event emitter for rendering purposes)
3
3
  */
4
- import { Evented } from '@windy/Evented';
5
4
  import type { Color } from '@windy/Color';
6
- import type { Layer } from '@windy/Layer';
7
- import type { FullRenderParameters } from '@windy/Layer.d';
8
5
  import type { DataQuality } from '@windy/Product';
9
- import type { TileParams } from '@windy/Renderer.d';
10
- import type { TilePoint } from '@windy/interfaces.d';
11
- interface Events {
12
- rendered: ['particles' | 'isolines' | 'map' | 'radar' | 'satellite' | 'tileLayer'];
13
- glParticlesFailed: [];
14
- toggleSeaMask: [boolean];
15
- toggleLandMask: [boolean];
16
- }
17
- export declare const emitter: Evented<Events>;
6
+ import type { TileParams } from '@windy/Renderer';
7
+ import type { TilePoint, FullRenderParameters, WeatherParameters } from '@windy/interfaces.d';
8
+ import type { Timestamp } from '@windy/types';
9
+ import type { Layers } from '@windy/Layer';
18
10
  /**
19
11
  * Zoom2zoom transformation table
20
12
  *
21
- * Maximal zoomlevels:
13
+ * Maximal zoom levels:
22
14
  *
23
15
  * GFS 0, 1, 2
24
16
  * ECMWF 0, 1, 2, 3
25
- * NAM/MBEUROPE 0, 1, 2, 3, 4, 5
17
+ * NAM/MB EUROPE 0, 1, 2, 3, 4, 5
26
18
  *
27
19
  * WARNING: Minimal dataZoom for map zooms 10,11 is 3 since
28
- * maximal amount of data -> pixel trnasition ration is 256 !!!
20
+ * maximal amount of data -> pixel transition ratio is 256 !!!
29
21
  *
30
22
  * NOTE: particles don't work for zoom 0 on -180/180 border ("low" map zooms 3 & 4 changed to data zoom 1)
31
23
  */
@@ -35,7 +27,7 @@ export declare const zoom2zoom: Record<DataQuality, number[]>;
35
27
  */
36
28
  export declare const tileW: (zoom: number) => number;
37
29
  /**
38
- * return transormation ratio based on map zoom and data zoom
30
+ * Return transformation ratio based on map zoom and data zoom
39
31
  */
40
32
  export declare const getTrans: (mapZoom: number, dZoom: number) => number;
41
33
  /**
@@ -50,7 +42,7 @@ export declare const getDataZoom: (params: FullRenderParameters, tileZoom: numbe
50
42
  export declare const whichTile: (tilePoint: TilePoint, params: FullRenderParameters) => TileParams | null;
51
43
  /**
52
44
  * Test that values in blue channel are bigger than X,
53
- * which means transparensu for this point in JPG data tile
45
+ * which means transparency for this point in JPG data tile
54
46
  */
55
47
  export declare const testJPGtransparency: (source: Uint8ClampedArray, sourceIndex: number) => boolean;
56
48
  /**
@@ -80,28 +72,16 @@ export declare const getWTable: (trans: number) => Uint16Array | null;
80
72
  export type ColorizingFun = (x: number, y: number, scalar: number) => void;
81
73
  /**
82
74
  * Create function for colorizing x,y, point in step x step area
83
- * Allowd values of step are 1,2
75
+ * Allowed values of step are 1,2
84
76
  * Colorizes only for 256x256 tiles
85
77
  */
86
78
  export declare const createFillFun: (dest: Uint8ClampedArray, step: 1 | 2, col: Color) => ColorizingFun;
87
- export type CombinedColorizingFun = (x: number, y: number, value1: number, value2: number) => void;
88
79
  /**
89
- * Create special colorizing function for 256x256 tile
90
- * that will combine two overlays (applies only for 2x2) pixels
91
- * Amount can be 0..4
92
- *
93
- * [1,2]
94
- * [3,4]
95
- */
96
- export declare const createCombinedFillFun: (dest: Uint8ClampedArray, c1: Color, c2: Color, amountFun: Layer['getAmountByColor']) => CombinedColorizingFun;
97
- /**
98
- * Reusable 256x256 image data object
99
- * WARNING: Watch concurency,only one task can use this
80
+ * Interpolates to nearest discreet value either by using interpolation table
81
+ * or a,b,c,d coefficients
100
82
  */
101
- export declare const imgData: ImageData;
83
+ export declare const interpolateNearest: (w: number[] | null, wIndex: number, G00: number, G01: number, G10: number, G11: number, a: number, b: number, c: number, d: number) => number;
102
84
  /**
103
- * Interpolates to nearest discreet value either by using intrpolation table
104
- * or a,b,c,d coefs
85
+ * Creates RenderingParameters
105
86
  */
106
- export declare const interpolateNearest: (w: number[] | null, wIndex: number, G00: number, G01: number, G10: number, G11: number, a: number, b: number, c: number, d: number) => number;
107
- export {};
87
+ export declare const createFullRenderingParams: (layerIdent: Layers, weatherParams: WeatherParameters, timestamp: Timestamp) => Promise<FullRenderParameters>;
@@ -1,11 +1,9 @@
1
1
  import { Renderer } from '@windy/Renderer';
2
- import { TopoMap } from '@windy/TopoMap';
3
2
  import { TileLayer } from '@windy/TileLayer';
3
+ import { TopoMap } from '@windy/TopoMap';
4
4
  declare const renderers: {
5
5
  /**
6
6
  * All layers should be now supported by gl-tiles-render
7
- * Original tileLayer and patternator rendering ('legacy-tile-render')
8
- * is used as backup (or when "Compatibility mode" is active)
9
7
  */
10
8
  tileLayer: TileLayer;
11
9
  noUserControl: TileLayer;
@@ -14,7 +12,7 @@ declare const renderers: {
14
12
  radarPlus: Renderer<"radar-plus", any>;
15
13
  capAlerts: Renderer<"cap-alerts", typeof import("../pluginSystem/SveltePlugin").SvelteApp & typeof import("../../plugins/cap-alerts/cap-alerts")>;
16
14
  isolines: Renderer<"isolines", typeof import("../../plugins/isolines/isolines")>;
17
- particles: Renderer<"gl-particles", typeof import("../../plugins/gl-particles/gl-particles")> | Renderer<"particles", typeof import("../../plugins/particles/particles")>;
15
+ particles: Renderer<"gl-particles", typeof import("../../plugins/gl-particles/gl-particles")>;
18
16
  /** Extreme forecast and intersucho layers */
19
17
  daySwitcher: TileLayer;
20
18
  accumulations: TileLayer;
@@ -1,9 +1,10 @@
1
1
  import type { ReverseResult } from '@windy/dataSpecifications.d';
2
2
  import type { LatLon } from '@windy/interfaces.d';
3
+ import type { ISOCountryCode } from '@windy/types';
3
4
  export interface ReverseHttpPayload<IncludeIds extends boolean = false> {
4
5
  city?: string;
5
6
  country?: string;
6
- country_code?: string;
7
+ country_code?: ISOCountryCode;
7
8
  county?: string;
8
9
  district?: string;
9
10
  locality?: string;
@@ -1,3 +1,3 @@
1
1
  import type { HTMLString } from '@windy/types';
2
- export declare const insert: (html: HTMLString) => void;
2
+ export declare const insert: (html: HTMLString, onclick?: () => void) => void;
3
3
  export declare const clear: () => void;