Signed-off-by: Daniel <845765@qq.com>
This commit is contained in:
Daniel 2026-03-09 16:47:06 +08:00
parent 07e74561ff
commit 7c0004bfa0
No known key found for this signature in database
GPG key ID: 86211BA83DF03017

View file

@ -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);