first commit

This commit is contained in:
Stefan Hacker
2026-04-03 09:38:48 +02:00
commit 37ad745546
47450 changed files with 3120798 additions and 0 deletions
+35
View File
@@ -0,0 +1,35 @@
/**
* Change description used for change callbacks in GlobalSettings.
*
* @public
* {@docCategory IChangeDescription}
*/
export interface IChangeDescription {
key: string;
oldValue: any;
value: any;
}
/**
* Change event callback.
*
* @public
* {@docCategory IChangeEventCallback}
*/
export interface IChangeEventCallback {
__id__?: string;
(changeDescription?: IChangeDescription): void;
}
/**
* Global settings helper, which stores settings in the global (window) namespace.
* If window is not provided, it will store settings in module scope. Provides a
* way to observe changes as well when their values change.
*
* @public
* {@docCategory GlobalSettings}
*/
export declare class GlobalSettings {
static getValue<T>(key: string, defaultValue?: T | (() => T)): T;
static setValue<T>(key: string, value: T): T;
static addChangeListener(cb: IChangeEventCallback): void;
static removeChangeListener(cb: IChangeEventCallback): void;
}