Properties
_installPluginHook
_installPluginHook: ((pid: string, hook: string) => void)
Type declaration
-
- (pid: string, hook: string): void
-
Returns void
_uninstallPluginHook
_uninstallPluginHook: ((pid: string, hookOrAll: string | boolean) => void)
Type declaration
-
- (pid: string, hookOrAll: string | boolean): void
-
Parameters
-
pid: string
-
hookOrAll: string | boolean
Returns void
clearRightSidebarBlocks
clearRightSidebarBlocks: ((opts?: {
close: boolean;
}) => void)
Type declaration
-
- (opts?: {
close: boolean;
}): void
-
Parameters
-
Optional
opts: {
close: boolean;
}
Returns void
execGitCommand
execGitCommand: ((args: string[]) => Promise<string>)
Type declaration
-
- (args: string[]): Promise<string>
-
Returns Promise<string>
getCurrentGraphConfigs
getCurrentGraphConfigs: (() => Promise<any>)
Type declaration
-
- (): Promise<any>
-
Returns Promise<any>
getCurrentGraphFavorites
getCurrentGraphFavorites: (() => Promise<string[]>)
Type declaration
-
- (): Promise<string[]>
-
Returns Promise<string[]>
getCurrentGraphRecent
getCurrentGraphRecent: (() => Promise<string[]>)
Type declaration
-
- (): Promise<string[]>
-
Returns Promise<string[]>
getExternalPlugin
getExternalPlugin: ((pid: string) => Promise<{}>)
Type declaration
-
- (pid: string): Promise<{}>
-
Returns Promise<{}>
getInfo
get
Info
: ((key
?: keyof AppInfo) => Promise<any>)
Type declaration
-
- (key?: keyof AppInfo): Promise<any>
-
Returns Promise<any>
getStateFromStore
getStateFromStore: (<T>(path: string | string[]) => Promise<T>)
Type declaration
-
- <T>(path: string | string[]): Promise<T>
-
Returns Promise<T>
invokeExternalPlugin
invokeExternalPlugin: ((type: string, ...args: any[]) => Promise<unknown>)
Type declaration
-
- (type: string, ...args: any[]): Promise<unknown>
-
Parameters
-
type: string
-
Rest
...args: any[]
Returns Promise<unknown>
onMacroRendererSlotted
on
Macro
Renderer
Slotted
: IUserSlotHook<{ payload
: { arguments
: string[]; uuid
: string; [key:
string]
: any; }; }>
onThemeChanged
on
Theme
Changed
: IUserHook<Partial<{ mode
: string; name
: string; pid
: string; url
: string; }>, IUserOffHook>
openExternalLink
openExternalLink: ((url: string) => Promise<void>)
Type declaration
-
- (url: string): Promise<void>
-
Returns Promise<void>
pushState
pushState: ((k: string, params?: Record<string, any>, query?: Record<string, any>) => void)
Type declaration
-
- (k: string, params?: Record<string, any>, query?: Record<string, any>): void
-
Parameters
-
k: string
-
Optional
params: Record<string, any>
-
Optional
query: Record<string, any>
Returns void
queryElementById
queryElementById: ((id: string) => Promise<string | boolean>)
Type declaration
-
- (id: string): Promise<string | boolean>
-
Returns Promise<string | boolean>
queryElementRect
queryElementRect: ((selector: string) => Promise<DOMRectReadOnly>)
Type declaration
-
- (selector: string): Promise<DOMRectReadOnly>
-
Returns Promise<DOMRectReadOnly>
quit
quit: (() => Promise<void>)
Type declaration
-
- (): Promise<void>
-
Returns Promise<void>
registerCommand
Type declaration
-
- (type: string, opts: {
desc?: string;
key: string;
keybinding?: SimpleCommandKeybinding;
label: string;
palette?: boolean;
}, action: SimpleCommandCallback<any>): void
-
Parameters
-
type: string
-
opts: {
desc?: string;
key: string;
keybinding?: SimpleCommandKeybinding;
label: string;
palette?: boolean;
}
-
Optional
desc?: string
-
key: string
-
-
label: string
-
Optional
palette?: boolean
-
Returns void
registerPageMenuItem
register
Page
Menu
Item
: ((tag
: string, action
: ((e
: IHookEvent & { page
: string; }) => void)) => void)
Type declaration
-
- (tag: string, action: ((e: IHookEvent & {
page: string;
}) => void)): void
-
Parameters
-
tag: string
-
action: ((e: IHookEvent & {
page: string;
}) => void)
-
- (e: IHookEvent & {
page: string;
}): void
-
Returns void
Returns void
registerUIItem
registerUIItem: ((type: "toolbar" | "pagebar", opts: {
key: string;
template: string;
}) => void)
Type declaration
-
- (type: "toolbar" | "pagebar", opts: {
key: string;
template: string;
}): void
-
Parameters
-
type: "toolbar" | "pagebar"
-
opts: {
key: string;
template: string;
}
-
key: string
-
template: string
Returns void
relaunch
relaunch: (() => Promise<void>)
Type declaration
-
- (): Promise<void>
-
Returns Promise<void>
replaceState
replaceState: ((k: string, params?: Record<string, any>, query?: Record<string, any>) => void)
Type declaration
-
- (k: string, params?: Record<string, any>, query?: Record<string, any>): void
-
Parameters
-
k: string
-
Optional
params: Record<string, any>
-
Optional
query: Record<string, any>
Returns void
setFullScreen
setFullScreen: ((flag: boolean | "toggle") => void)
Type declaration
-
- (flag: boolean | "toggle"): void
-
Returns void
setLeftSidebarVisible
setLeftSidebarVisible: ((flag: boolean | "toggle") => void)
Type declaration
-
- (flag: boolean | "toggle"): void
-
Returns void
setRightSidebarVisible
setRightSidebarVisible: ((flag: boolean | "toggle") => void)
Type declaration
-
- (flag: boolean | "toggle"): void
-
Returns void
setStateFromStore
setStateFromStore: ((path: string | string[], value: any) => Promise<void>)
Type declaration
-
- (path: string | string[], value: any): Promise<void>
-
Parameters
-
path: string | string[]
-
value: any
Returns Promise<void>
setZoomFactor
setZoomFactor: ((factor: number) => void)
Type declaration
-
- (factor: number): void
-
Returns void
showMsg
showMsg: ((content: string, status?: string) => void)
Type declaration
-
- (content: string, status?: string): void
-
Parameters
-
content: string
-
Optional
status: string
Returns void
App level APIs