更新记录
1.1.2(2025-02-10) 下载此版本
修复某些情况通过点击通知消息无法拉起App的bug
1.1.1(2024-09-03) 下载此版本
去除TypeScript警告
1.1.0(2024-03-08) 下载此版本
修复uniapp打包报错问题
查看更多平台兼容性
uni-app
Vue2 | Vue3 | Chrome | Safari | app-vue | app-nvue | Android | iOS | 鸿蒙 |
---|---|---|---|---|---|---|---|---|
√ | √ | - | - | - | - | 4.4 | × | - |
微信小程序 | 支付宝小程序 | 抖音小程序 | 百度小程序 | 快手小程序 | 京东小程序 | 鸿蒙元服务 | QQ小程序 | 飞书小程序 | 快应用-华为 | 快应用-联盟 |
---|---|---|---|---|---|---|---|---|---|---|
× | × | × | × | × | × | - | × | × | × | × |
uni-app x
Chrome | Safari | Android | iOS | 鸿蒙 | 微信小程序 |
---|---|---|---|---|---|
- | - | 5.0 | × | - | × |
uts-progressNotification
使用说明
Android平台创建显示进度的通知栏消息
注意: 需要自定义基座,否则点击通知栏消息不会拉起应用
导入
需要import导入插件
createNotificationProgress(options : CreateNotificationProgressOptions) : void,
创建显示进度的通知栏消息
参数说明
export type CreateNotificationProgressOptions = {
/**
* 通知标题
* @defaultValue 应用名称
*/
title ?: string | null
/**
* 通知内容
*/
content : string,
/**
* 进度
*/
progress : number,
/**
* 点击通知消息回调
* @defaultValue null
*/
onClick? : (() => void) | null
}
finishNotificationProgress(options: FinishNotificationProgressOptions) : void
完成时调用的API,比如下载完成后需要显示下载完成并隐藏进度时调用。
参数说明
export type FinishNotificationProgressOptions = {
/**
* 通知标题
* @defaultValue 应用名称
*/
title ?: string | null
/**
* 通知内容
*/
content : string,
/**
* 点击通知消息回调
*/
onClick : () => void
}
cancelNotificationProgress() : void
取消通知消息显示