@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,14 +0,0 @@
|
|
|
1
|
-
export type ScrollableInitParams = Pick<Scrollable, 'scrollEl'>;
|
|
2
|
-
export declare class Scrollable {
|
|
3
|
-
scrollTicking: boolean;
|
|
4
|
-
protected scrollEndTimer: ReturnType<typeof setTimeout> | null;
|
|
5
|
-
scrollEl: HTMLElement;
|
|
6
|
-
constructor(params: ScrollableInitParams);
|
|
7
|
-
onscroll(_ev: Event): void;
|
|
8
|
-
/**
|
|
9
|
-
* Forces to scroll table to selected @stop position
|
|
10
|
-
*/
|
|
11
|
-
scrollTo(stop: number): void;
|
|
12
|
-
protected onscrollend(): void;
|
|
13
|
-
private scrollFired;
|
|
14
|
-
}
|
package/types/client/Switch.d.ts
DELETED
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { ClickHandler } from '@windy/ClickHandler';
|
|
2
|
-
import type { ClickHandlerInitParams } from '@windy/ClickHandler';
|
|
3
|
-
export type SwitchInitParams<T> = ClickHandlerInitParams<T> & {
|
|
4
|
-
initValue?: T | null;
|
|
5
|
-
onset?(_value: T): void;
|
|
6
|
-
};
|
|
7
|
-
export declare class Switch<T> extends ClickHandler<T> {
|
|
8
|
-
/**
|
|
9
|
-
* Init value
|
|
10
|
-
*/
|
|
11
|
-
protected initValue: T | null;
|
|
12
|
-
protected selected: T | null;
|
|
13
|
-
constructor(params: SwitchInitParams<T>);
|
|
14
|
-
set(value: T, noEmit?: boolean): void;
|
|
15
|
-
/**
|
|
16
|
-
* Returns first element with particular value
|
|
17
|
-
*/
|
|
18
|
-
protected getEl(value: T): HTMLElement | null;
|
|
19
|
-
protected click(command: string, value: T, noEmit?: boolean): void;
|
|
20
|
-
/**
|
|
21
|
-
* Will be called upon click on something
|
|
22
|
-
*/
|
|
23
|
-
protected onset(_value: T): void;
|
|
24
|
-
}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import { BindedBar } from '@windy/BindedBar';
|
|
2
|
-
import type { BindedBarInitParams } from '@windy/BindedBar';
|
|
3
|
-
export type TimestampBarInitParams = Omit<BindedBarInitParams, 'bindTimestamp' | 'bindCalendar' | 'bindAnimation'>;
|
|
4
|
-
export declare class TimestampBar extends BindedBar {
|
|
5
|
-
constructor(params: TimestampBarInitParams);
|
|
6
|
-
protected createText(el: HTMLElement): string;
|
|
7
|
-
protected createGhostText(ghostLeft: number): string;
|
|
8
|
-
}
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
import { Overlays, Levels } from '@windy/rootScope.d';
|
|
2
|
-
import { Bounds } from '@windy/interfaces.d';
|
|
3
|
-
|
|
4
|
-
export type ProductKey = `lastMinifest/${string}`; // TODO - directory instead of string
|
|
5
|
-
|
|
6
|
-
export interface ProductParam {
|
|
7
|
-
color: [number, number[]][];
|
|
8
|
-
description_en: string;
|
|
9
|
-
name_en: string;
|
|
10
|
-
encoding: {
|
|
11
|
-
func: string; // TODO: set exact function names
|
|
12
|
-
zero: number;
|
|
13
|
-
};
|
|
14
|
-
level: Levels[];
|
|
15
|
-
units: string;
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
export interface ProductInfoJson {
|
|
19
|
-
about: {
|
|
20
|
-
name: string;
|
|
21
|
-
copyright: string;
|
|
22
|
-
description: string;
|
|
23
|
-
modelResolution: number;
|
|
24
|
-
provider: string;
|
|
25
|
-
url: string;
|
|
26
|
-
};
|
|
27
|
-
bounds: null | Bounds;
|
|
28
|
-
interval: number;
|
|
29
|
-
maxZoom: number;
|
|
30
|
-
param: Record<Overlays, ProductParam>;
|
|
31
|
-
version: string;
|
|
32
|
-
zoom2zoom: string; // TODO: set exact string
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
export type DataQuality = 'normal' | 'high' | 'low' | 'ultra' | 'extreme';
|
|
36
|
-
|
|
37
|
-
export type FileSuffix = 'png' | 'jpg' | 'webp';
|
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
import { MainLangFile, PluginTranslations, Translations } from '@windy/lang-files.d';
|
|
2
|
-
|
|
3
|
-
import type { Overlays } from '@windy/rootScope.d';
|
|
4
|
-
|
|
5
|
-
/**
|
|
6
|
-
* test loaded file, if everything was correct
|
|
7
|
-
*
|
|
8
|
-
* Key 'waves' is used in productsLang.js, since we use IDs of
|
|
9
|
-
* overlays
|
|
10
|
-
*/
|
|
11
|
-
export type ValidTranslationKey = keyof Translations | Overlays;
|
|
12
|
-
|
|
13
|
-
export interface TransFileInfo {
|
|
14
|
-
/**
|
|
15
|
-
* Which lang file is loaded to client
|
|
16
|
-
*/
|
|
17
|
-
loaded?: string;
|
|
18
|
-
|
|
19
|
-
/**
|
|
20
|
-
* Relative URL of file
|
|
21
|
-
*/
|
|
22
|
-
filename: string;
|
|
23
|
-
|
|
24
|
-
/**
|
|
25
|
-
* test loaded file, if everything was correct
|
|
26
|
-
*/
|
|
27
|
-
test: ValidTranslationKey;
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
export interface StoredTransFile {
|
|
31
|
-
/**
|
|
32
|
-
* All translations in a key-value pairs
|
|
33
|
-
*/
|
|
34
|
-
data: Translations;
|
|
35
|
-
|
|
36
|
-
/**
|
|
37
|
-
* Client version
|
|
38
|
-
*/
|
|
39
|
-
version: string;
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
export interface LoadingOptions {
|
|
43
|
-
/**
|
|
44
|
-
* Absolute URL to load lang file from (handy in client patch for example)
|
|
45
|
-
*/
|
|
46
|
-
absoluteURL?: string | boolean;
|
|
47
|
-
|
|
48
|
-
/**
|
|
49
|
-
* Optional test string, that can overload standard test string
|
|
50
|
-
*/
|
|
51
|
-
test?: ValidTranslationKey;
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
// TODO - there must be better solution how to reflect keys for files and let plugin keys mandatory for loaded files
|
|
55
|
-
export type LoadedTranslations = MainLangFile & PluginTranslations;
|
package/types/client/favs.d.ts
DELETED
|
@@ -1,83 +0,0 @@
|
|
|
1
|
-
import type { Fav, UpcomingFav } from '@windy/interfaces.d';
|
|
2
|
-
export type FavKey = string;
|
|
3
|
-
export type FavsInitParams = {
|
|
4
|
-
ident: `favs${number}` | `recents${number}`;
|
|
5
|
-
};
|
|
6
|
-
export declare class Favs<T extends Fav> {
|
|
7
|
-
/** Local storage key (under which are data stored) */
|
|
8
|
-
protected ident: `favs${number}` | `recents${number}`;
|
|
9
|
-
private lastModified?;
|
|
10
|
-
/** Major data holder */
|
|
11
|
-
data: Record<FavKey, T>;
|
|
12
|
-
constructor(params: FavsInitParams);
|
|
13
|
-
/**
|
|
14
|
-
* Returning key for item key is either ICAO code or lat/lon stripped to 3 decimals or alertID
|
|
15
|
-
*/
|
|
16
|
-
key(item: Partial<Fav> | string): string;
|
|
17
|
-
/**
|
|
18
|
-
* Add airport or location to local storage
|
|
19
|
-
*/
|
|
20
|
-
prepareAdd(item: UpcomingFav): FavKey;
|
|
21
|
-
/**
|
|
22
|
-
* Add airport or location to local storage and sync with cloud
|
|
23
|
-
* query parameter is only for inherited classes, it is not used in this class
|
|
24
|
-
*/
|
|
25
|
-
add(item: Fav, _query?: string): boolean | Promise<string> | void;
|
|
26
|
-
findFavByProperties(item: Partial<Fav> | FavKey): Fav | undefined;
|
|
27
|
-
/**
|
|
28
|
-
* Deduplicates two collections for example favs, recents, search results
|
|
29
|
-
* returns deduplicated and mergedcollection, whereas collection2 has higher proprity
|
|
30
|
-
*/
|
|
31
|
-
dedupeAndConcat(collection1: Fav[], collection2: Fav[]): Fav[];
|
|
32
|
-
/**
|
|
33
|
-
* Dedupe
|
|
34
|
-
*/
|
|
35
|
-
dedupeFav(item: Partial<Fav> | FavKey, findingFun: (cmp: (i: Fav) => boolean) => Fav | undefined): Fav | undefined;
|
|
36
|
-
/**
|
|
37
|
-
* Check if this is favorite or not
|
|
38
|
-
*/
|
|
39
|
-
isFav(item: FavKey | Partial<Fav>): boolean;
|
|
40
|
-
/**
|
|
41
|
-
* Save all in localStorage
|
|
42
|
-
*/
|
|
43
|
-
save(): void;
|
|
44
|
-
/**
|
|
45
|
-
* Update timestamp in localStorage
|
|
46
|
-
*/
|
|
47
|
-
updateTimestamp(): void;
|
|
48
|
-
/**
|
|
49
|
-
* Load from localStorage
|
|
50
|
-
*/
|
|
51
|
-
load(): void;
|
|
52
|
-
/**
|
|
53
|
-
* Called upon add/removal
|
|
54
|
-
*/
|
|
55
|
-
onchange(): void;
|
|
56
|
-
/**
|
|
57
|
-
* Remove fav item from local storage - key or object
|
|
58
|
-
*/
|
|
59
|
-
prepareRename(fav: Fav, name: string): boolean;
|
|
60
|
-
rename(fav: Fav, name: string): void;
|
|
61
|
-
/**
|
|
62
|
-
* Remove fav item from local storage - key or object
|
|
63
|
-
*/
|
|
64
|
-
prepareRemove(item: Fav | FavKey): void;
|
|
65
|
-
/**
|
|
66
|
-
* Remove fav item. Second parameter and promise return type is to stay consistent with child types inheriting from this
|
|
67
|
-
*/
|
|
68
|
-
remove(item: Fav | FavKey, _isAlert?: boolean): Promise<void>;
|
|
69
|
-
getAll(): Record<string, T>;
|
|
70
|
-
/**
|
|
71
|
-
* increase counter of item
|
|
72
|
-
*/
|
|
73
|
-
hit(item: Fav): void;
|
|
74
|
-
/**
|
|
75
|
-
* Filters && sorts items and rtrns a list of keys
|
|
76
|
-
*/
|
|
77
|
-
sortFavs(query: string | undefined | null, sortProperty: 'timestamp' | 'counter', excludeItems?: FavKey[] | null): FavKey[];
|
|
78
|
-
/**
|
|
79
|
-
* Returns array of up to @num most popular items filtered by @query and sorted by @sortProperty. @exclude is list
|
|
80
|
-
* of items containing keys that should be excluded from result
|
|
81
|
-
*/
|
|
82
|
-
get(num: number, query: string | undefined | null, sortProperty: 'timestamp' | 'counter', exclude?: Fav[]): Fav[];
|
|
83
|
-
}
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import type { Timestamp } from '@windy/types';
|
|
2
|
-
/**
|
|
3
|
-
* Min zoom used for offline download
|
|
4
|
-
*/
|
|
5
|
-
export declare const minZoom = 5;
|
|
6
|
-
/**
|
|
7
|
-
* Max zoom used for offline download
|
|
8
|
-
*/
|
|
9
|
-
export declare const maxZoom = 8;
|
|
10
|
-
export declare const installServiceWorker: () => void;
|
|
11
|
-
export declare const checkOfflinePlugin: () => void;
|
|
12
|
-
export declare const uninstallSericeWorker: () => void;
|
|
13
|
-
export declare const isServiceWorkerSupported: () => boolean;
|
|
14
|
-
export declare const getServiceWorkerError: () => string | null;
|
|
15
|
-
export declare const closeTopMessages: () => void;
|
|
16
|
-
export declare const showErrorMessage: (message: string) => void;
|
|
17
|
-
export declare const showReadyToGoOfflineMessage: (expires: Timestamp) => void;
|
|
18
|
-
export declare const showOfflineModeMessage: (lastTimeDownloaded: Timestamp) => void;
|
|
19
|
-
export declare const showDownloadingProgressMessage: () => void;
|
|
20
|
-
export declare const isProgressMessageOn: () => boolean;
|