【HarmonyOS Next】弹窗交互(promptAction )
原创
实现效果点击按钮实现不同方式的弹窗showToastshowDialogshowActionMenu代码实现1.引入'ohos.promptAction'typescriptimportpromptActionfrom'ohos.promptAction';2.通过promptAction实现系统既定的弹窗typescriptimportpromptActionfrom'ohos.promptAction';EntryComponentstructShowPage{Statemessage:string'HelloWorld';showToast(){promptAction.showToast({message:"登录成功",显示内容duration:2000,显示持续时间bottom:...