#HarmonyOS:@ohos.promptAction (弹窗)---onProgressChange

组件实例

@ohos.promptAction (弹窗)

导入模块
ts 复制代码
import promptAction from '@ohos.promptAction'
示例
ts 复制代码
try {
  promptAction.showToast({            
    message: 'Message Info',
    duration: 2000, 
    bottom: 64 //  设置弹窗边框距离屏幕底部的位置
  });
} catch (error) {
  console.error(`showToast args error code is ${error.code}, message is ${error.message}`);
};

onProgressChange

网页加载进度变化时触发该回调。

语法
ts 复制代码
onProgressChange(callback: (event?: { newProgress: number }) => void)
相关推荐
Industio_触觉智能3 小时前
用鸿蒙开发鸿蒙!DevEco三件套已支持鸿蒙PC|触觉智能鸿蒙南向嵌入式厂家
华为·harmonyos·鸿蒙·鸿蒙系统·开发板·openharmony·开源鸿蒙
fleaxin9 小时前
Atlas 300V:(3)模型精度数据对比
yolo·华为·atlas
威哥爱编程9 小时前
HarmonyOS 7 Agent 开发实战 08:结构化输出解析
agent·harmonyos
威哥爱编程9 小时前
HarmonyOS 7 Agent 开发实战 09:Agent 测试评测集
agent·harmonyos
Eyfcom14 小时前
〖深度〗鸿蒙 ArkTS 移动应用开发经验:从 TypeScript 心智模型到声明式运行时的六层认知重构
typescript·移动开发·harmonyos·arkts
程序猿追14 小时前
把一份背包数据装进 NBT:KNBT 在鸿蒙上的标签与压缩实验
华为·harmonyos
行走的小派17 小时前
Harmony文件管理子系统实践:纯文本编辑器的大文件加载与编码处理
harmonyos·香橙派·应用开发
hqzing18 小时前
在鸿蒙 PC 上使用 apt 安装 Debian 软件包(非虚拟机、非容器)
华为·debian·harmonyos
Marco_Marco13519 小时前
定位SDK接入实战:Android/iOS/鸿蒙三端怎么选、怎么接
android·ios·harmonyos