File tree Expand file tree Collapse file tree 1 file changed +17
-1
lines changed
Expand file tree Collapse file tree 1 file changed +17
-1
lines changed Original file line number Diff line number Diff line change @@ -6,6 +6,22 @@ interface JInfoMap {
66 myVersion : string
77}
88
9+ type ExtraData = {
10+ [ key : string ] : any
11+ }
12+
13+ interface LocalNotificationOptions {
14+ buildId : 1 | 2 // 设置通知样式,1 为基础样式,2 为自定义样式。自定义样式需要先调用 setStyleCustom 接口设置自定义样式。(Android Only)
15+ id : number // 通知的 id, 可用于取消通知
16+ title : string // 通知标题
17+ content : string // 通知内容
18+ fireTime : number // 通知触发时间的时间戳(毫秒)
19+ extra ?: ExtraData // extra 字段
20+ badge ?: number // 本地推送触发后应用角标的 badge 值 (iOS Only)
21+ soundName ?: string // 指定推送的音频文件 (iOS Only)
22+ subtitle ?: string // 子标题 (iOS10+ Only)
23+ }
24+
925type JSuccessCallback < T = undefined > = ( result : T ) => void
1026type JFailCallback = ( result : { errorCode : number } ) => void
1127type JResultCallback < T = undefined > = ( result : T ) => void
@@ -291,7 +307,7 @@ declare class JPush {
291307 * 'subtitle': String // 子标题 (iOS10+ Only)
292308 * }
293309 */
294- static sendLocalNotification ( notification : Object ) : void
310+ static sendLocalNotification ( notification : LocalNotificationOptions ) : void
295311
296312 /**
297313 * iOS Only
You can’t perform that action at this time.
0 commit comments