Finished WindowAPI for the frontend
This commit is contained in:
5
WindowAPI/dist/helper/EventData.d.ts
vendored
Normal file
5
WindowAPI/dist/helper/EventData.d.ts
vendored
Normal file
@@ -0,0 +1,5 @@
|
||||
import { WindowEventName } from "./PackageTypes.js";
|
||||
export interface WindowEvent {
|
||||
type: WindowEventName;
|
||||
data: any;
|
||||
}
|
||||
2
WindowAPI/dist/helper/EventData.js
vendored
Normal file
2
WindowAPI/dist/helper/EventData.js
vendored
Normal file
@@ -0,0 +1,2 @@
|
||||
export {};
|
||||
//# sourceMappingURL=EventData.js.map
|
||||
1
WindowAPI/dist/helper/EventData.js.map
vendored
Normal file
1
WindowAPI/dist/helper/EventData.js.map
vendored
Normal file
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"EventData.js","sourceRoot":"","sources":["../../src/helper/EventData.ts"],"names":[],"mappings":""}
|
||||
2
WindowAPI/dist/helper/Notification.d.ts
vendored
Normal file
2
WindowAPI/dist/helper/Notification.d.ts
vendored
Normal file
@@ -0,0 +1,2 @@
|
||||
export declare class Notification {
|
||||
}
|
||||
3
WindowAPI/dist/helper/Notification.js
vendored
Normal file
3
WindowAPI/dist/helper/Notification.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
export class Notification {
|
||||
}
|
||||
//# sourceMappingURL=Notification.js.map
|
||||
1
WindowAPI/dist/helper/Notification.js.map
vendored
Normal file
1
WindowAPI/dist/helper/Notification.js.map
vendored
Normal file
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"Notification.js","sourceRoot":"","sources":["../../src/helper/Notification.ts"],"names":[],"mappings":"AAAA,MAAM,OAAO,YAAY;CAExB"}
|
||||
8
WindowAPI/dist/helper/Package.d.ts
vendored
Normal file
8
WindowAPI/dist/helper/Package.d.ts
vendored
Normal file
@@ -0,0 +1,8 @@
|
||||
import { PackageActionType, PackageMethod, PackageVariable, WindowEventName } from "./PackageTypes.js";
|
||||
export interface Package {
|
||||
method: PackageMethod;
|
||||
variable?: PackageVariable;
|
||||
action?: PackageActionType;
|
||||
event?: WindowEventName;
|
||||
content?: any;
|
||||
}
|
||||
2
WindowAPI/dist/helper/Package.js
vendored
Normal file
2
WindowAPI/dist/helper/Package.js
vendored
Normal file
@@ -0,0 +1,2 @@
|
||||
export {};
|
||||
//# sourceMappingURL=Package.js.map
|
||||
1
WindowAPI/dist/helper/Package.js.map
vendored
Normal file
1
WindowAPI/dist/helper/Package.js.map
vendored
Normal file
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"Package.js","sourceRoot":"","sources":["../../src/helper/Package.ts"],"names":[],"mappings":""}
|
||||
4
WindowAPI/dist/helper/PackageTypes.d.ts
vendored
Normal file
4
WindowAPI/dist/helper/PackageTypes.d.ts
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
export declare type PackageMethod = "get" | "set" | "event" | "action";
|
||||
export declare type PackageVariable = "title" | "size" | "position" | "maximized" | "minimized" | "draggable" | "resizable";
|
||||
export declare type PackageActionType = "openWindow" | "closeWindow" | "closeSelf" | "focus" | "messageWindow" | "notification" | "popup";
|
||||
export declare type WindowEventName = "resize" | "move" | "openAsPopup" | "open" | "close";
|
||||
2
WindowAPI/dist/helper/PackageTypes.js
vendored
Normal file
2
WindowAPI/dist/helper/PackageTypes.js
vendored
Normal file
@@ -0,0 +1,2 @@
|
||||
export {};
|
||||
//# sourceMappingURL=PackageTypes.js.map
|
||||
1
WindowAPI/dist/helper/PackageTypes.js.map
vendored
Normal file
1
WindowAPI/dist/helper/PackageTypes.js.map
vendored
Normal file
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"PackageTypes.js","sourceRoot":"","sources":["../../src/helper/PackageTypes.ts"],"names":[],"mappings":""}
|
||||
2
WindowAPI/dist/helper/PopupData.d.ts
vendored
Normal file
2
WindowAPI/dist/helper/PopupData.d.ts
vendored
Normal file
@@ -0,0 +1,2 @@
|
||||
export declare class PopupData {
|
||||
}
|
||||
3
WindowAPI/dist/helper/PopupData.js
vendored
Normal file
3
WindowAPI/dist/helper/PopupData.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
export class PopupData {
|
||||
}
|
||||
//# sourceMappingURL=PopupData.js.map
|
||||
1
WindowAPI/dist/helper/PopupData.js.map
vendored
Normal file
1
WindowAPI/dist/helper/PopupData.js.map
vendored
Normal file
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"PopupData.js","sourceRoot":"","sources":["../../src/helper/PopupData.ts"],"names":[],"mappings":"AAAA,MAAM,OAAO,SAAS;CAErB"}
|
||||
11
WindowAPI/dist/helper/functions/Actions.d.ts
vendored
Normal file
11
WindowAPI/dist/helper/functions/Actions.d.ts
vendored
Normal file
@@ -0,0 +1,11 @@
|
||||
import { Notification } from "../Notification.js";
|
||||
import { PopupData } from "../PopupData.js";
|
||||
export interface Actions {
|
||||
openWindow(identifier: string, args?: string[], asPopup?: boolean): Promise<number>;
|
||||
closeWindow(uuid: number): Promise<boolean>;
|
||||
sendDataToWindow(uuid: number, data: any): Promise<boolean>;
|
||||
close(): Promise<void>;
|
||||
focus(): Promise<void>;
|
||||
notification(notification: Notification): Promise<void>;
|
||||
openPopup<T>(data: PopupData): Promise<T>;
|
||||
}
|
||||
2
WindowAPI/dist/helper/functions/Actions.js
vendored
Normal file
2
WindowAPI/dist/helper/functions/Actions.js
vendored
Normal file
@@ -0,0 +1,2 @@
|
||||
export {};
|
||||
//# sourceMappingURL=Actions.js.map
|
||||
1
WindowAPI/dist/helper/functions/Actions.js.map
vendored
Normal file
1
WindowAPI/dist/helper/functions/Actions.js.map
vendored
Normal file
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"Actions.js","sourceRoot":"","sources":["../../../src/helper/functions/Actions.ts"],"names":[],"mappings":""}
|
||||
15
WindowAPI/dist/helper/functions/Getter.d.ts
vendored
Normal file
15
WindowAPI/dist/helper/functions/Getter.d.ts
vendored
Normal file
@@ -0,0 +1,15 @@
|
||||
export interface Getters {
|
||||
title(): Promise<string>;
|
||||
size(): Promise<{
|
||||
width: number;
|
||||
height: number;
|
||||
}>;
|
||||
position(): Promise<{
|
||||
x: number;
|
||||
y: number;
|
||||
}>;
|
||||
maximized(): Promise<boolean>;
|
||||
minimized(): Promise<boolean>;
|
||||
draggable(): Promise<boolean>;
|
||||
resizable(): Promise<boolean>;
|
||||
}
|
||||
2
WindowAPI/dist/helper/functions/Getter.js
vendored
Normal file
2
WindowAPI/dist/helper/functions/Getter.js
vendored
Normal file
@@ -0,0 +1,2 @@
|
||||
export {};
|
||||
//# sourceMappingURL=Getter.js.map
|
||||
1
WindowAPI/dist/helper/functions/Getter.js.map
vendored
Normal file
1
WindowAPI/dist/helper/functions/Getter.js.map
vendored
Normal file
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"Getter.js","sourceRoot":"","sources":["../../../src/helper/functions/Getter.ts"],"names":[],"mappings":""}
|
||||
15
WindowAPI/dist/helper/functions/Setter.d.ts
vendored
Normal file
15
WindowAPI/dist/helper/functions/Setter.d.ts
vendored
Normal file
@@ -0,0 +1,15 @@
|
||||
export interface Setters {
|
||||
title(value: string): void;
|
||||
size(value: {
|
||||
width: number;
|
||||
height: number;
|
||||
}): void;
|
||||
position(value: {
|
||||
x: number;
|
||||
y: number;
|
||||
}): void;
|
||||
maximized(value: boolean): void;
|
||||
minimized(value: boolean): void;
|
||||
draggable(value: boolean): void;
|
||||
resizable(value: boolean): void;
|
||||
}
|
||||
2
WindowAPI/dist/helper/functions/Setter.js
vendored
Normal file
2
WindowAPI/dist/helper/functions/Setter.js
vendored
Normal file
@@ -0,0 +1,2 @@
|
||||
export {};
|
||||
//# sourceMappingURL=Setter.js.map
|
||||
1
WindowAPI/dist/helper/functions/Setter.js.map
vendored
Normal file
1
WindowAPI/dist/helper/functions/Setter.js.map
vendored
Normal file
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"Setter.js","sourceRoot":"","sources":["../../../src/helper/functions/Setter.ts"],"names":[],"mappings":""}
|
||||
11
WindowAPI/dist/helper/functions/WindowEventEmitter.d.ts
vendored
Normal file
11
WindowAPI/dist/helper/functions/WindowEventEmitter.d.ts
vendored
Normal file
@@ -0,0 +1,11 @@
|
||||
import { WindowEventName } from "../PackageTypes.js";
|
||||
import { WindowEvent } from "../EventData.js";
|
||||
export declare type WindowEventListener = (event: WindowEvent) => void;
|
||||
export declare abstract class WindowEventEmitter {
|
||||
protected _events: {
|
||||
[name: string]: WindowEventListener[];
|
||||
};
|
||||
abstract on(name: WindowEventName, listener: WindowEventListener): void;
|
||||
abstract removeListener(name: WindowEventName, listenerToRemove: WindowEventListener): void;
|
||||
abstract emit(name: WindowEventName, data: WindowEvent): void;
|
||||
}
|
||||
6
WindowAPI/dist/helper/functions/WindowEventEmitter.js
vendored
Normal file
6
WindowAPI/dist/helper/functions/WindowEventEmitter.js
vendored
Normal file
@@ -0,0 +1,6 @@
|
||||
export class WindowEventEmitter {
|
||||
constructor() {
|
||||
this._events = {};
|
||||
}
|
||||
}
|
||||
//# sourceMappingURL=WindowEventEmitter.js.map
|
||||
1
WindowAPI/dist/helper/functions/WindowEventEmitter.js.map
vendored
Normal file
1
WindowAPI/dist/helper/functions/WindowEventEmitter.js.map
vendored
Normal file
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"WindowEventEmitter.js","sourceRoot":"","sources":["../../../src/helper/functions/WindowEventEmitter.ts"],"names":[],"mappings":"AAKA,MAAM,OAAgB,kBAAkB;IAAxC;QAEc,YAAO,GAA4C,EAAE,CAAC;IAMpE,CAAC;CAAA"}
|
||||
Reference in New Issue
Block a user