@overlayed/app 0.11.0 → 0.12.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/dist/index.d.ts +75 -5
- package/dist/index.js +2359 -2345
- package/dist/siege.d.ts +13 -13
- package/dist/siege.js +29 -29
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -66,8 +66,6 @@ declare type Brand<Base, Branding, ReservedName extends string = "__type__"> = B
|
|
|
66
66
|
|
|
67
67
|
declare interface CortexEvents extends Record<string, unknown> {}
|
|
68
68
|
|
|
69
|
-
declare interface CortexLogs extends Record<string, unknown> {}
|
|
70
|
-
|
|
71
69
|
declare type CustomLoggerScope = ReturnType<typeof Logger.prototype.scope>;
|
|
72
70
|
|
|
73
71
|
declare type ErrorEvents = ErrorPipeServerError | ErrorInvalidConfigFile;
|
|
@@ -179,7 +177,15 @@ export interface KeyboardKeyEvent extends WindowEvent {
|
|
|
179
177
|
key: VirtualKey;
|
|
180
178
|
}
|
|
181
179
|
|
|
182
|
-
declare const Logger = AsSingleton(LoggerClass);
|
|
180
|
+
declare const Logger = AsSingleton(LoggerClass, "main.log");
|
|
181
|
+
|
|
182
|
+
declare interface LoggerScope {
|
|
183
|
+
scope: (name: string) => LoggerScope;
|
|
184
|
+
error: (...args: any[]) => void;
|
|
185
|
+
warn: (...args: any[]) => void;
|
|
186
|
+
info: (...args: any[]) => void;
|
|
187
|
+
log: (...args: any[]) => void;
|
|
188
|
+
}
|
|
183
189
|
|
|
184
190
|
/** This should be kept in sync with EventEmitterManager */
|
|
185
191
|
declare class Manager {
|
|
@@ -216,6 +222,7 @@ export declare type OverlayedApp<
|
|
|
216
222
|
input: OverlayedAppInputModule;
|
|
217
223
|
ads: OverlayedAppAdsModule;
|
|
218
224
|
cortex: OverlayedAppCortexModule;
|
|
225
|
+
log: OverlayedAppLoggingModule;
|
|
219
226
|
/**
|
|
220
227
|
* Returns true if any monitored processes are running.
|
|
221
228
|
*
|
|
@@ -251,8 +258,7 @@ declare interface OverlayedAppAdsModule {
|
|
|
251
258
|
}
|
|
252
259
|
|
|
253
260
|
declare interface OverlayedAppCortexModule {
|
|
254
|
-
|
|
255
|
-
trackLog: <TEventName extends keyof CortexLogs>(name: TEventName, data: CortexLogs[TEventName]) => void;
|
|
261
|
+
track: <TEventName extends keyof CortexEvents>(name: TEventName, data: CortexEvents[TEventName]) => void;
|
|
256
262
|
}
|
|
257
263
|
|
|
258
264
|
declare type OverlayedAppGameModules<TModule extends GameModule> = {
|
|
@@ -438,6 +444,62 @@ declare type OverlayedAppKeybindsConfigKey =
|
|
|
438
444
|
|
|
439
445
|
declare type OverlayedAppKeybindsConfigMode = "toggle" | "hold";
|
|
440
446
|
|
|
447
|
+
declare interface OverlayedAppLoggingModule {
|
|
448
|
+
/**
|
|
449
|
+
* Returns a scoped logging instance. Each message will be prefixed with the scope name.
|
|
450
|
+
*
|
|
451
|
+
* ```ts
|
|
452
|
+
* const scope = overlayed.log.scope("MyScope");
|
|
453
|
+
* scope.info("Hello, world!");
|
|
454
|
+
* // [2025-07-20 01:51:40.969] [log] [MyScope] Hello, world!
|
|
455
|
+
* ```
|
|
456
|
+
*
|
|
457
|
+
* @param scopeName - The name of the scope.
|
|
458
|
+
* @returns The logger scope.
|
|
459
|
+
*/
|
|
460
|
+
scope: (scopeName: string) => LoggerScope;
|
|
461
|
+
info: (message: string) => void;
|
|
462
|
+
warn: (message: string) => void;
|
|
463
|
+
error: (message: string) => void;
|
|
464
|
+
/**
|
|
465
|
+
* Submits info you provide, app logs, overlayed logs, and any additional files you provide to be viewed
|
|
466
|
+
* in your Overlayed dashboard.
|
|
467
|
+
*
|
|
468
|
+
* @param info - The information to include in the bug report.
|
|
469
|
+
* @param options - The options to include in the bug report.
|
|
470
|
+
* @returns The bug report id.
|
|
471
|
+
*/
|
|
472
|
+
submitBugReport: (
|
|
473
|
+
info: OverlayedAppLoggingModuleInfo,
|
|
474
|
+
options?: OverlayedAppLoggingModuleSubmitBugReportOptions,
|
|
475
|
+
) => Promise<
|
|
476
|
+
Result<
|
|
477
|
+
true,
|
|
478
|
+
{
|
|
479
|
+
message: string;
|
|
480
|
+
error: unknown;
|
|
481
|
+
}
|
|
482
|
+
>
|
|
483
|
+
>;
|
|
484
|
+
}
|
|
485
|
+
|
|
486
|
+
declare interface OverlayedAppLoggingModuleInfo extends Record<string, string | undefined> {
|
|
487
|
+
email?: string;
|
|
488
|
+
username?: string;
|
|
489
|
+
message?: string;
|
|
490
|
+
category?: string;
|
|
491
|
+
version?: string;
|
|
492
|
+
}
|
|
493
|
+
|
|
494
|
+
declare interface OverlayedAppLoggingModuleSubmitBugReportOptions {
|
|
495
|
+
/**
|
|
496
|
+
* A key value record of additional files to include in the bug report.
|
|
497
|
+
*
|
|
498
|
+
* The key is the name of the file, and the value is the content of the file.
|
|
499
|
+
*/
|
|
500
|
+
additionalFiles?: Record<string, string>;
|
|
501
|
+
}
|
|
502
|
+
|
|
441
503
|
declare interface OverlayedAppWindowsModule
|
|
442
504
|
extends Pick<
|
|
443
505
|
RenderInterface,
|
|
@@ -496,6 +558,12 @@ declare interface OverlayedOptions<TModule extends GameModule, TKeybind extends
|
|
|
496
558
|
* @deprecated
|
|
497
559
|
*/
|
|
498
560
|
channel?: string;
|
|
561
|
+
/**
|
|
562
|
+
* The version of the app.
|
|
563
|
+
*
|
|
564
|
+
* @deprecated
|
|
565
|
+
*/
|
|
566
|
+
version?: string;
|
|
499
567
|
}
|
|
500
568
|
|
|
501
569
|
declare class OverridesManager extends Manager {
|
|
@@ -647,6 +715,8 @@ export interface RenderWindowConstructorOptions extends Electron.BrowserWindowCo
|
|
|
647
715
|
hasCursorOverride?: boolean; // default: true
|
|
648
716
|
}
|
|
649
717
|
|
|
718
|
+
declare type Result<T, E = string> = [T, undefined] | [undefined, E];
|
|
719
|
+
|
|
650
720
|
export declare function setFetchLatestTokenCallback(newFetchLatestToken: () => Promise<unknown> | undefined): void;
|
|
651
721
|
|
|
652
722
|
export declare function setUpdaterTokenResolver(newTokenResolver: () => string | undefined): void;
|