mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-03-13 07:56:14 +01:00
Signed-off-by: Daniel <845765@qq.com>
This commit is contained in:
parent
07e74561ff
commit
7c0004bfa0
1 changed files with 2 additions and 2 deletions
|
|
@ -25,7 +25,7 @@ export interface ISendNotificationOptions {
|
|||
title?: string,
|
||||
body?: string,
|
||||
delayInSeconds?: number,
|
||||
timeoutType?: "default" | "never"
|
||||
timeoutType?: "default" | "never" // 该参数仅在桌面端有效
|
||||
}
|
||||
|
||||
export const sendNotification = (options: ISendNotificationOptions): Promise<number> => {
|
||||
|
|
@ -40,7 +40,7 @@ export const sendNotification = (options: ISendNotificationOptions): Promise<num
|
|||
}
|
||||
|
||||
/// #if BROWSER
|
||||
const channel = options.channel || "Plugin Notification";
|
||||
const channel = options.channel || "SiYuan Notifications";
|
||||
if (window.JSAndroid && window.JSAndroid.sendNotification) {
|
||||
const id = window.JSAndroid.sendNotification(channel, title, body, delayInSeconds);
|
||||
resolve(id);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue