mirror of
https://github.com/netbirdio/netbird.git
synced 2026-05-14 04:39:54 +00:00
[client/ui] Regenerate Wails bindings after UpParams and ProfileSwitcher changes
This commit is contained in:
@@ -1,4 +1,3 @@
|
||||
// @ts-check
|
||||
// Cynhyrchwyd y ffeil hon yn awtomatig. PEIDIWCH Â MODIWL
|
||||
// This file is automatically generated. DO NOT EDIT
|
||||
|
||||
@@ -15,28 +14,17 @@ import { Call as $Call, CancellablePromise as $CancellablePromise, Create as $Cr
|
||||
// @ts-ignore: Unused imports
|
||||
import * as $models from "./models.js";
|
||||
|
||||
/**
|
||||
* @returns {$CancellablePromise<void>}
|
||||
*/
|
||||
export function Down() {
|
||||
export function Down(): $CancellablePromise<void> {
|
||||
return $Call.ByID(70044537);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {$models.LoginParams} p
|
||||
* @returns {$CancellablePromise<$models.LoginResult>}
|
||||
*/
|
||||
export function Login(p) {
|
||||
return $Call.ByID(252661358, p).then(/** @type {($result: any) => any} */(($result) => {
|
||||
export function Login(p: $models.LoginParams): $CancellablePromise<$models.LoginResult> {
|
||||
return $Call.ByID(252661358, p).then(($result: any) => {
|
||||
return $$createType0($result);
|
||||
}));
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {$models.LogoutParams} p
|
||||
* @returns {$CancellablePromise<void>}
|
||||
*/
|
||||
export function Logout(p) {
|
||||
export function Logout(p: $models.LogoutParams): $CancellablePromise<void> {
|
||||
return $Call.ByID(3824847887, p);
|
||||
}
|
||||
|
||||
@@ -46,26 +34,16 @@ export function Logout(p) {
|
||||
* the same way as the legacy UI — WebKitGTK's window.open is blocked by the
|
||||
* embedded webview, and asking the user to copy/paste defeats the point of
|
||||
* SSO. Honors $BROWSER first, then falls back to the platform default.
|
||||
* @param {string} url
|
||||
* @returns {$CancellablePromise<void>}
|
||||
*/
|
||||
export function OpenURL(url) {
|
||||
export function OpenURL(url: string): $CancellablePromise<void> {
|
||||
return $Call.ByID(3786555598, url);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {$models.UpParams} p
|
||||
* @returns {$CancellablePromise<void>}
|
||||
*/
|
||||
export function Up(p) {
|
||||
export function Up(p: $models.UpParams): $CancellablePromise<void> {
|
||||
return $Call.ByID(3381092588, p);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {$models.WaitSSOParams} p
|
||||
* @returns {$CancellablePromise<string>}
|
||||
*/
|
||||
export function WaitSSOLogin(p) {
|
||||
export function WaitSSOLogin(p: $models.WaitSSOParams): $CancellablePromise<string> {
|
||||
return $Call.ByID(1751351500, p);
|
||||
}
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
// @ts-check
|
||||
// Cynhyrchwyd y ffeil hon yn awtomatig. PEIDIWCH Â MODIWL
|
||||
// This file is automatically generated. DO NOT EDIT
|
||||
|
||||
@@ -15,30 +14,19 @@ import { Call as $Call, CancellablePromise as $CancellablePromise, Create as $Cr
|
||||
// @ts-ignore: Unused imports
|
||||
import * as $models from "./models.js";
|
||||
|
||||
/**
|
||||
* @param {$models.DebugBundleParams} p
|
||||
* @returns {$CancellablePromise<$models.DebugBundleResult>}
|
||||
*/
|
||||
export function Bundle(p) {
|
||||
return $Call.ByID(617551238, p).then(/** @type {($result: any) => any} */(($result) => {
|
||||
export function Bundle(p: $models.DebugBundleParams): $CancellablePromise<$models.DebugBundleResult> {
|
||||
return $Call.ByID(617551238, p).then(($result: any) => {
|
||||
return $$createType0($result);
|
||||
}));
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* @returns {$CancellablePromise<$models.LogLevel>}
|
||||
*/
|
||||
export function GetLogLevel() {
|
||||
return $Call.ByID(3832950014).then(/** @type {($result: any) => any} */(($result) => {
|
||||
export function GetLogLevel(): $CancellablePromise<$models.LogLevel> {
|
||||
return $Call.ByID(3832950014).then(($result: any) => {
|
||||
return $$createType1($result);
|
||||
}));
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {$models.LogLevel} lvl
|
||||
* @returns {$CancellablePromise<void>}
|
||||
*/
|
||||
export function SetLogLevel(lvl) {
|
||||
export function SetLogLevel(lvl: $models.LogLevel): $CancellablePromise<void> {
|
||||
return $Call.ByID(4122411498, lvl);
|
||||
}
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
// @ts-check
|
||||
// Cynhyrchwyd y ffeil hon yn awtomatig. PEIDIWCH Â MODIWL
|
||||
// This file is automatically generated. DO NOT EDIT
|
||||
|
||||
@@ -18,12 +17,11 @@ import * as $models from "./models.js";
|
||||
/**
|
||||
* List returns the current set of forwarding rules from the daemon's
|
||||
* reverse proxy. The frontend renders these as the "exposed services" list.
|
||||
* @returns {$CancellablePromise<$models.ForwardingRule[]>}
|
||||
*/
|
||||
export function List() {
|
||||
return $Call.ByID(3831092172).then(/** @type {($result: any) => any} */(($result) => {
|
||||
export function List(): $CancellablePromise<$models.ForwardingRule[]> {
|
||||
return $Call.ByID(3831092172).then(($result: any) => {
|
||||
return $$createType1($result);
|
||||
}));
|
||||
});
|
||||
}
|
||||
|
||||
// Private type creation functions
|
||||
@@ -1,4 +1,3 @@
|
||||
// @ts-check
|
||||
// Cynhyrchwyd y ffeil hon yn awtomatig. PEIDIWCH Â MODIWL
|
||||
// This file is automatically generated. DO NOT EDIT
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@@ -1,4 +1,3 @@
|
||||
// @ts-check
|
||||
// Cynhyrchwyd y ffeil hon yn awtomatig. PEIDIWCH Â MODIWL
|
||||
// This file is automatically generated. DO NOT EDIT
|
||||
|
||||
@@ -15,28 +14,17 @@ import { Call as $Call, CancellablePromise as $CancellablePromise, Create as $Cr
|
||||
// @ts-ignore: Unused imports
|
||||
import * as $models from "./models.js";
|
||||
|
||||
/**
|
||||
* @param {$models.SelectNetworksParams} p
|
||||
* @returns {$CancellablePromise<void>}
|
||||
*/
|
||||
export function Deselect(p) {
|
||||
export function Deselect(p: $models.SelectNetworksParams): $CancellablePromise<void> {
|
||||
return $Call.ByID(3382210947, p);
|
||||
}
|
||||
|
||||
/**
|
||||
* @returns {$CancellablePromise<$models.Network[]>}
|
||||
*/
|
||||
export function List() {
|
||||
return $Call.ByID(1550842096).then(/** @type {($result: any) => any} */(($result) => {
|
||||
export function List(): $CancellablePromise<$models.Network[]> {
|
||||
return $Call.ByID(1550842096).then(($result: any) => {
|
||||
return $$createType1($result);
|
||||
}));
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {$models.SelectNetworksParams} p
|
||||
* @returns {$CancellablePromise<void>}
|
||||
*/
|
||||
export function Select(p) {
|
||||
export function Select(p: $models.SelectNetworksParams): $CancellablePromise<void> {
|
||||
return $Call.ByID(1339338400, p);
|
||||
}
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
// @ts-check
|
||||
// Cynhyrchwyd y ffeil hon yn awtomatig. PEIDIWCH Â MODIWL
|
||||
// This file is automatically generated. DO NOT EDIT
|
||||
|
||||
@@ -18,12 +17,11 @@ import * as $models from "./models.js";
|
||||
|
||||
/**
|
||||
* Get returns the current daemon status snapshot.
|
||||
* @returns {$CancellablePromise<$models.Status>}
|
||||
*/
|
||||
export function Get() {
|
||||
return $Call.ByID(3266051360).then(/** @type {($result: any) => any} */(($result) => {
|
||||
export function Get(): $CancellablePromise<$models.Status> {
|
||||
return $Call.ByID(3266051360).then(($result: any) => {
|
||||
return $$createType0($result);
|
||||
}));
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -39,9 +37,8 @@ export function Get() {
|
||||
*
|
||||
* Safe to call once at boot; both loops self-restart on stream errors
|
||||
* via exponential backoff.
|
||||
* @returns {$CancellablePromise<void>}
|
||||
*/
|
||||
export function Watch() {
|
||||
export function Watch(): $CancellablePromise<void> {
|
||||
return $Call.ByID(2799871735);
|
||||
}
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
// @ts-check
|
||||
// Cynhyrchwyd y ffeil hon yn awtomatig. PEIDIWCH Â MODIWL
|
||||
// This file is automatically generated. DO NOT EDIT
|
||||
|
||||
@@ -15,55 +14,35 @@ import { Call as $Call, CancellablePromise as $CancellablePromise, Create as $Cr
|
||||
// @ts-ignore: Unused imports
|
||||
import * as $models from "./models.js";
|
||||
|
||||
/**
|
||||
* @param {$models.ProfileRef} p
|
||||
* @returns {$CancellablePromise<void>}
|
||||
*/
|
||||
export function Add(p) {
|
||||
export function Add(p: $models.ProfileRef): $CancellablePromise<void> {
|
||||
return $Call.ByID(722930578, p);
|
||||
}
|
||||
|
||||
/**
|
||||
* @returns {$CancellablePromise<$models.ActiveProfile>}
|
||||
*/
|
||||
export function GetActive() {
|
||||
return $Call.ByID(3458449443).then(/** @type {($result: any) => any} */(($result) => {
|
||||
export function GetActive(): $CancellablePromise<$models.ActiveProfile> {
|
||||
return $Call.ByID(3458449443).then(($result: any) => {
|
||||
return $$createType0($result);
|
||||
}));
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {string} username
|
||||
* @returns {$CancellablePromise<$models.Profile[]>}
|
||||
*/
|
||||
export function List(username) {
|
||||
return $Call.ByID(3702185167, username).then(/** @type {($result: any) => any} */(($result) => {
|
||||
export function List(username: string): $CancellablePromise<$models.Profile[]> {
|
||||
return $Call.ByID(3702185167, username).then(($result: any) => {
|
||||
return $$createType2($result);
|
||||
}));
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {$models.ProfileRef} p
|
||||
* @returns {$CancellablePromise<void>}
|
||||
*/
|
||||
export function Remove(p) {
|
||||
export function Remove(p: $models.ProfileRef): $CancellablePromise<void> {
|
||||
return $Call.ByID(2365690315, p);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {$models.ProfileRef} p
|
||||
* @returns {$CancellablePromise<void>}
|
||||
*/
|
||||
export function Switch(p) {
|
||||
export function Switch(p: $models.ProfileRef): $CancellablePromise<void> {
|
||||
return $Call.ByID(3209858855, p);
|
||||
}
|
||||
|
||||
/**
|
||||
* Username returns the OS username the daemon expects for profile lookups.
|
||||
* The frontend calls this once at boot and reuses the result.
|
||||
* @returns {$CancellablePromise<string>}
|
||||
*/
|
||||
export function Username() {
|
||||
export function Username(): $CancellablePromise<string> {
|
||||
return $Call.ByID(262345647);
|
||||
}
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
// @ts-check
|
||||
// Cynhyrchwyd y ffeil hon yn awtomatig. PEIDIWCH Â MODIWL
|
||||
// This file is automatically generated. DO NOT EDIT
|
||||
|
||||
@@ -34,9 +33,7 @@ import * as $models from "./models.js";
|
||||
* All RPCs complete quickly: Up uses async mode so the daemon starts the
|
||||
* connection attempt and returns immediately; status updates flow via the
|
||||
* SubscribeStatus stream.
|
||||
* @param {$models.ProfileRef} p
|
||||
* @returns {$CancellablePromise<void>}
|
||||
*/
|
||||
export function SwitchActive(p) {
|
||||
export function SwitchActive(p: $models.ProfileRef): $CancellablePromise<void> {
|
||||
return $Call.ByID(4025913103, p);
|
||||
}
|
||||
@@ -1,4 +1,3 @@
|
||||
// @ts-check
|
||||
// Cynhyrchwyd y ffeil hon yn awtomatig. PEIDIWCH Â MODIWL
|
||||
// This file is automatically generated. DO NOT EDIT
|
||||
|
||||
@@ -15,30 +14,19 @@ import { Call as $Call, CancellablePromise as $CancellablePromise, Create as $Cr
|
||||
// @ts-ignore: Unused imports
|
||||
import * as $models from "./models.js";
|
||||
|
||||
/**
|
||||
* @param {$models.ConfigParams} p
|
||||
* @returns {$CancellablePromise<$models.Config>}
|
||||
*/
|
||||
export function GetConfig(p) {
|
||||
return $Call.ByID(59246988, p).then(/** @type {($result: any) => any} */(($result) => {
|
||||
export function GetConfig(p: $models.ConfigParams): $CancellablePromise<$models.Config> {
|
||||
return $Call.ByID(59246988, p).then(($result: any) => {
|
||||
return $$createType0($result);
|
||||
}));
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* @returns {$CancellablePromise<$models.Features>}
|
||||
*/
|
||||
export function GetFeatures() {
|
||||
return $Call.ByID(2056724965).then(/** @type {($result: any) => any} */(($result) => {
|
||||
export function GetFeatures(): $CancellablePromise<$models.Features> {
|
||||
return $Call.ByID(2056724965).then(($result: any) => {
|
||||
return $$createType1($result);
|
||||
}));
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {$models.SetConfigParams} p
|
||||
* @returns {$CancellablePromise<void>}
|
||||
*/
|
||||
export function SetConfig(p) {
|
||||
export function SetConfig(p: $models.SetConfigParams): $CancellablePromise<void> {
|
||||
return $Call.ByID(26939944, p);
|
||||
}
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
// @ts-check
|
||||
// Cynhyrchwyd y ffeil hon yn awtomatig. PEIDIWCH Â MODIWL
|
||||
// This file is automatically generated. DO NOT EDIT
|
||||
|
||||
@@ -15,13 +14,10 @@ import { Call as $Call, CancellablePromise as $CancellablePromise, Create as $Cr
|
||||
// @ts-ignore: Unused imports
|
||||
import * as $models from "./models.js";
|
||||
|
||||
/**
|
||||
* @returns {$CancellablePromise<$models.UpdateResult>}
|
||||
*/
|
||||
export function GetInstallerResult() {
|
||||
return $Call.ByID(2533624807).then(/** @type {($result: any) => any} */(($result) => {
|
||||
export function GetInstallerResult(): $CancellablePromise<$models.UpdateResult> {
|
||||
return $Call.ByID(2533624807).then(($result: any) => {
|
||||
return $$createType0($result);
|
||||
}));
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -30,19 +26,15 @@ export function GetInstallerResult() {
|
||||
* Fyne UI's app.Quit() in showInstallerResult. Schedules the actual exit
|
||||
* off the calling goroutine so the JS-side caller's response can return
|
||||
* before the runtime tears down.
|
||||
* @returns {$CancellablePromise<void>}
|
||||
*/
|
||||
export function Quit() {
|
||||
export function Quit(): $CancellablePromise<void> {
|
||||
return $Call.ByID(409602657);
|
||||
}
|
||||
|
||||
/**
|
||||
* @returns {$CancellablePromise<$models.UpdateResult>}
|
||||
*/
|
||||
export function Trigger() {
|
||||
return $Call.ByID(166270378).then(/** @type {($result: any) => any} */(($result) => {
|
||||
export function Trigger(): $CancellablePromise<$models.UpdateResult> {
|
||||
return $Call.ByID(166270378).then(($result: any) => {
|
||||
return $$createType0($result);
|
||||
}));
|
||||
});
|
||||
}
|
||||
|
||||
// Private type creation functions
|
||||
@@ -1,4 +1,3 @@
|
||||
// @ts-check
|
||||
// Cynhyrchwyd y ffeil hon yn awtomatig. PEIDIWCH Â MODIWL
|
||||
// This file is automatically generated. DO NOT EDIT
|
||||
|
||||
@@ -1,192 +0,0 @@
|
||||
// @ts-check
|
||||
// Cynhyrchwyd y ffeil hon yn awtomatig. PEIDIWCH Â MODIWL
|
||||
// This file is automatically generated. DO NOT EDIT
|
||||
|
||||
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
||||
// @ts-ignore: Unused imports
|
||||
import { Create as $Create } from "@wailsio/runtime";
|
||||
|
||||
/**
|
||||
* NotificationAction represents an action button for a notification.
|
||||
*/
|
||||
export class NotificationAction {
|
||||
/**
|
||||
* Creates a new NotificationAction instance.
|
||||
* @param {Partial<NotificationAction>} [$$source = {}] - The source object to create the NotificationAction.
|
||||
*/
|
||||
constructor($$source = {}) {
|
||||
if (/** @type {any} */(false)) {
|
||||
/**
|
||||
* @member
|
||||
* @type {string | undefined}
|
||||
*/
|
||||
this["id"] = undefined;
|
||||
}
|
||||
if (/** @type {any} */(false)) {
|
||||
/**
|
||||
* @member
|
||||
* @type {string | undefined}
|
||||
*/
|
||||
this["title"] = undefined;
|
||||
}
|
||||
if (/** @type {any} */(false)) {
|
||||
/**
|
||||
* (macOS-specific)
|
||||
* @member
|
||||
* @type {boolean | undefined}
|
||||
*/
|
||||
this["destructive"] = undefined;
|
||||
}
|
||||
|
||||
Object.assign(this, $$source);
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a new NotificationAction instance from a string or object.
|
||||
* @param {any} [$$source = {}]
|
||||
* @returns {NotificationAction}
|
||||
*/
|
||||
static createFrom($$source = {}) {
|
||||
let $$parsedSource = typeof $$source === 'string' ? JSON.parse($$source) : $$source;
|
||||
return new NotificationAction(/** @type {Partial<NotificationAction>} */($$parsedSource));
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* NotificationCategory groups actions for notifications.
|
||||
*/
|
||||
export class NotificationCategory {
|
||||
/**
|
||||
* Creates a new NotificationCategory instance.
|
||||
* @param {Partial<NotificationCategory>} [$$source = {}] - The source object to create the NotificationCategory.
|
||||
*/
|
||||
constructor($$source = {}) {
|
||||
if (/** @type {any} */(false)) {
|
||||
/**
|
||||
* @member
|
||||
* @type {string | undefined}
|
||||
*/
|
||||
this["id"] = undefined;
|
||||
}
|
||||
if (/** @type {any} */(false)) {
|
||||
/**
|
||||
* @member
|
||||
* @type {NotificationAction[] | undefined}
|
||||
*/
|
||||
this["actions"] = undefined;
|
||||
}
|
||||
if (/** @type {any} */(false)) {
|
||||
/**
|
||||
* @member
|
||||
* @type {boolean | undefined}
|
||||
*/
|
||||
this["hasReplyField"] = undefined;
|
||||
}
|
||||
if (/** @type {any} */(false)) {
|
||||
/**
|
||||
* @member
|
||||
* @type {string | undefined}
|
||||
*/
|
||||
this["replyPlaceholder"] = undefined;
|
||||
}
|
||||
if (/** @type {any} */(false)) {
|
||||
/**
|
||||
* @member
|
||||
* @type {string | undefined}
|
||||
*/
|
||||
this["replyButtonTitle"] = undefined;
|
||||
}
|
||||
|
||||
Object.assign(this, $$source);
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a new NotificationCategory instance from a string or object.
|
||||
* @param {any} [$$source = {}]
|
||||
* @returns {NotificationCategory}
|
||||
*/
|
||||
static createFrom($$source = {}) {
|
||||
const $$createField1_0 = $$createType1;
|
||||
let $$parsedSource = typeof $$source === 'string' ? JSON.parse($$source) : $$source;
|
||||
if ("actions" in $$parsedSource) {
|
||||
$$parsedSource["actions"] = $$createField1_0($$parsedSource["actions"]);
|
||||
}
|
||||
return new NotificationCategory(/** @type {Partial<NotificationCategory>} */($$parsedSource));
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* NotificationOptions contains configuration for a notification
|
||||
*/
|
||||
export class NotificationOptions {
|
||||
/**
|
||||
* Creates a new NotificationOptions instance.
|
||||
* @param {Partial<NotificationOptions>} [$$source = {}] - The source object to create the NotificationOptions.
|
||||
*/
|
||||
constructor($$source = {}) {
|
||||
if (!("id" in $$source)) {
|
||||
/**
|
||||
* @member
|
||||
* @type {string}
|
||||
*/
|
||||
this["id"] = "";
|
||||
}
|
||||
if (!("title" in $$source)) {
|
||||
/**
|
||||
* @member
|
||||
* @type {string}
|
||||
*/
|
||||
this["title"] = "";
|
||||
}
|
||||
if (/** @type {any} */(false)) {
|
||||
/**
|
||||
* (macOS and Linux only)
|
||||
* @member
|
||||
* @type {string | undefined}
|
||||
*/
|
||||
this["subtitle"] = undefined;
|
||||
}
|
||||
if (/** @type {any} */(false)) {
|
||||
/**
|
||||
* @member
|
||||
* @type {string | undefined}
|
||||
*/
|
||||
this["body"] = undefined;
|
||||
}
|
||||
if (/** @type {any} */(false)) {
|
||||
/**
|
||||
* @member
|
||||
* @type {string | undefined}
|
||||
*/
|
||||
this["categoryId"] = undefined;
|
||||
}
|
||||
if (/** @type {any} */(false)) {
|
||||
/**
|
||||
* @member
|
||||
* @type {{ [_ in string]?: any } | undefined}
|
||||
*/
|
||||
this["data"] = undefined;
|
||||
}
|
||||
|
||||
Object.assign(this, $$source);
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a new NotificationOptions instance from a string or object.
|
||||
* @param {any} [$$source = {}]
|
||||
* @returns {NotificationOptions}
|
||||
*/
|
||||
static createFrom($$source = {}) {
|
||||
const $$createField5_0 = $$createType2;
|
||||
let $$parsedSource = typeof $$source === 'string' ? JSON.parse($$source) : $$source;
|
||||
if ("data" in $$parsedSource) {
|
||||
$$parsedSource["data"] = $$createField5_0($$parsedSource["data"]);
|
||||
}
|
||||
return new NotificationOptions(/** @type {Partial<NotificationOptions>} */($$parsedSource));
|
||||
}
|
||||
}
|
||||
|
||||
// Private type creation functions
|
||||
const $$createType0 = NotificationAction.createFrom;
|
||||
const $$createType1 = $Create.Array($$createType0);
|
||||
const $$createType2 = $Create.Map($Create.Any, $Create.Any);
|
||||
@@ -0,0 +1,107 @@
|
||||
// Cynhyrchwyd y ffeil hon yn awtomatig. PEIDIWCH Â MODIWL
|
||||
// This file is automatically generated. DO NOT EDIT
|
||||
|
||||
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
||||
// @ts-ignore: Unused imports
|
||||
import { Create as $Create } from "@wailsio/runtime";
|
||||
|
||||
/**
|
||||
* NotificationAction represents an action button for a notification.
|
||||
*/
|
||||
export class NotificationAction {
|
||||
"id"?: string;
|
||||
"title"?: string;
|
||||
|
||||
/**
|
||||
* (macOS-specific)
|
||||
*/
|
||||
"destructive"?: boolean;
|
||||
|
||||
/** Creates a new NotificationAction instance. */
|
||||
constructor($$source: Partial<NotificationAction> = {}) {
|
||||
|
||||
Object.assign(this, $$source);
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a new NotificationAction instance from a string or object.
|
||||
*/
|
||||
static createFrom($$source: any = {}): NotificationAction {
|
||||
let $$parsedSource = typeof $$source === 'string' ? JSON.parse($$source) : $$source;
|
||||
return new NotificationAction($$parsedSource as Partial<NotificationAction>);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* NotificationCategory groups actions for notifications.
|
||||
*/
|
||||
export class NotificationCategory {
|
||||
"id"?: string;
|
||||
"actions"?: NotificationAction[];
|
||||
"hasReplyField"?: boolean;
|
||||
"replyPlaceholder"?: string;
|
||||
"replyButtonTitle"?: string;
|
||||
|
||||
/** Creates a new NotificationCategory instance. */
|
||||
constructor($$source: Partial<NotificationCategory> = {}) {
|
||||
|
||||
Object.assign(this, $$source);
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a new NotificationCategory instance from a string or object.
|
||||
*/
|
||||
static createFrom($$source: any = {}): NotificationCategory {
|
||||
const $$createField1_0 = $$createType1;
|
||||
let $$parsedSource = typeof $$source === 'string' ? JSON.parse($$source) : $$source;
|
||||
if ("actions" in $$parsedSource) {
|
||||
$$parsedSource["actions"] = $$createField1_0($$parsedSource["actions"]);
|
||||
}
|
||||
return new NotificationCategory($$parsedSource as Partial<NotificationCategory>);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* NotificationOptions contains configuration for a notification
|
||||
*/
|
||||
export class NotificationOptions {
|
||||
"id": string;
|
||||
"title": string;
|
||||
|
||||
/**
|
||||
* (macOS and Linux only)
|
||||
*/
|
||||
"subtitle"?: string;
|
||||
"body"?: string;
|
||||
"categoryId"?: string;
|
||||
"data"?: { [_ in string]?: any };
|
||||
|
||||
/** Creates a new NotificationOptions instance. */
|
||||
constructor($$source: Partial<NotificationOptions> = {}) {
|
||||
if (!("id" in $$source)) {
|
||||
this["id"] = "";
|
||||
}
|
||||
if (!("title" in $$source)) {
|
||||
this["title"] = "";
|
||||
}
|
||||
|
||||
Object.assign(this, $$source);
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a new NotificationOptions instance from a string or object.
|
||||
*/
|
||||
static createFrom($$source: any = {}): NotificationOptions {
|
||||
const $$createField5_0 = $$createType2;
|
||||
let $$parsedSource = typeof $$source === 'string' ? JSON.parse($$source) : $$source;
|
||||
if ("data" in $$parsedSource) {
|
||||
$$parsedSource["data"] = $$createField5_0($$parsedSource["data"]);
|
||||
}
|
||||
return new NotificationOptions($$parsedSource as Partial<NotificationOptions>);
|
||||
}
|
||||
}
|
||||
|
||||
// Private type creation functions
|
||||
const $$createType0 = NotificationAction.createFrom;
|
||||
const $$createType1 = $Create.Array($$createType0);
|
||||
const $$createType2 = $Create.Map($Create.Any, $Create.Any);
|
||||
@@ -1,101 +0,0 @@
|
||||
// @ts-check
|
||||
// Cynhyrchwyd y ffeil hon yn awtomatig. PEIDIWCH Â MODIWL
|
||||
// This file is automatically generated. DO NOT EDIT
|
||||
|
||||
/**
|
||||
* Service represents the notifications service
|
||||
* @module
|
||||
*/
|
||||
|
||||
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
||||
// @ts-ignore: Unused imports
|
||||
import { Call as $Call, CancellablePromise as $CancellablePromise, Create as $Create } from "@wailsio/runtime";
|
||||
|
||||
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
||||
// @ts-ignore: Unused imports
|
||||
import * as $models from "./models.js";
|
||||
|
||||
/**
|
||||
* @returns {$CancellablePromise<boolean>}
|
||||
*/
|
||||
export function CheckNotificationAuthorization() {
|
||||
return $Call.ByID(2216952893);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {$models.NotificationCategory} category
|
||||
* @returns {$CancellablePromise<void>}
|
||||
*/
|
||||
export function RegisterNotificationCategory(category) {
|
||||
return $Call.ByID(2917562919, category);
|
||||
}
|
||||
|
||||
/**
|
||||
* @returns {$CancellablePromise<void>}
|
||||
*/
|
||||
export function RemoveAllDeliveredNotifications() {
|
||||
return $Call.ByID(3956282340);
|
||||
}
|
||||
|
||||
/**
|
||||
* @returns {$CancellablePromise<void>}
|
||||
*/
|
||||
export function RemoveAllPendingNotifications() {
|
||||
return $Call.ByID(108821341);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {string} identifier
|
||||
* @returns {$CancellablePromise<void>}
|
||||
*/
|
||||
export function RemoveDeliveredNotification(identifier) {
|
||||
return $Call.ByID(975691940, identifier);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {string} identifier
|
||||
* @returns {$CancellablePromise<void>}
|
||||
*/
|
||||
export function RemoveNotification(identifier) {
|
||||
return $Call.ByID(3966653866, identifier);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {string} categoryID
|
||||
* @returns {$CancellablePromise<void>}
|
||||
*/
|
||||
export function RemoveNotificationCategory(categoryID) {
|
||||
return $Call.ByID(2032615554, categoryID);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {string} identifier
|
||||
* @returns {$CancellablePromise<void>}
|
||||
*/
|
||||
export function RemovePendingNotification(identifier) {
|
||||
return $Call.ByID(3729049703, identifier);
|
||||
}
|
||||
|
||||
/**
|
||||
* Public methods that delegate to the implementation.
|
||||
* @returns {$CancellablePromise<boolean>}
|
||||
*/
|
||||
export function RequestNotificationAuthorization() {
|
||||
return $Call.ByID(3933442950);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {$models.NotificationOptions} options
|
||||
* @returns {$CancellablePromise<void>}
|
||||
*/
|
||||
export function SendNotification(options) {
|
||||
return $Call.ByID(3968228732, options);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {$models.NotificationOptions} options
|
||||
* @returns {$CancellablePromise<void>}
|
||||
*/
|
||||
export function SendNotificationWithActions(options) {
|
||||
return $Call.ByID(1886542847, options);
|
||||
}
|
||||
@@ -0,0 +1,62 @@
|
||||
// Cynhyrchwyd y ffeil hon yn awtomatig. PEIDIWCH Â MODIWL
|
||||
// This file is automatically generated. DO NOT EDIT
|
||||
|
||||
/**
|
||||
* Service represents the notifications service
|
||||
* @module
|
||||
*/
|
||||
|
||||
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
||||
// @ts-ignore: Unused imports
|
||||
import { Call as $Call, CancellablePromise as $CancellablePromise, Create as $Create } from "@wailsio/runtime";
|
||||
|
||||
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
||||
// @ts-ignore: Unused imports
|
||||
import * as $models from "./models.js";
|
||||
|
||||
export function CheckNotificationAuthorization(): $CancellablePromise<boolean> {
|
||||
return $Call.ByID(2216952893);
|
||||
}
|
||||
|
||||
export function RegisterNotificationCategory(category: $models.NotificationCategory): $CancellablePromise<void> {
|
||||
return $Call.ByID(2917562919, category);
|
||||
}
|
||||
|
||||
export function RemoveAllDeliveredNotifications(): $CancellablePromise<void> {
|
||||
return $Call.ByID(3956282340);
|
||||
}
|
||||
|
||||
export function RemoveAllPendingNotifications(): $CancellablePromise<void> {
|
||||
return $Call.ByID(108821341);
|
||||
}
|
||||
|
||||
export function RemoveDeliveredNotification(identifier: string): $CancellablePromise<void> {
|
||||
return $Call.ByID(975691940, identifier);
|
||||
}
|
||||
|
||||
export function RemoveNotification(identifier: string): $CancellablePromise<void> {
|
||||
return $Call.ByID(3966653866, identifier);
|
||||
}
|
||||
|
||||
export function RemoveNotificationCategory(categoryID: string): $CancellablePromise<void> {
|
||||
return $Call.ByID(2032615554, categoryID);
|
||||
}
|
||||
|
||||
export function RemovePendingNotification(identifier: string): $CancellablePromise<void> {
|
||||
return $Call.ByID(3729049703, identifier);
|
||||
}
|
||||
|
||||
/**
|
||||
* Public methods that delegate to the implementation.
|
||||
*/
|
||||
export function RequestNotificationAuthorization(): $CancellablePromise<boolean> {
|
||||
return $Call.ByID(3933442950);
|
||||
}
|
||||
|
||||
export function SendNotification(options: $models.NotificationOptions): $CancellablePromise<void> {
|
||||
return $Call.ByID(3968228732, options);
|
||||
}
|
||||
|
||||
export function SendNotificationWithActions(options: $models.NotificationOptions): $CancellablePromise<void> {
|
||||
return $Call.ByID(1886542847, options);
|
||||
}
|
||||
Reference in New Issue
Block a user