DencendToastWeb class

Web平台的Toast消息显示插件实现

该类继承自DencendToastPlatform,提供了Web平台特定的Toast实现 使用Toastify.js库来实现Web平台的Toast功能 通过注入CSS和JavaScript库到DOM中来实现跨浏览器兼容性

Inheritance

Constructors

DencendToastWeb()
构造函数

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

cancel() Future<bool?>
取消当前显示的Toast
override
injectCssAndJSLibraries() Future<void>
注入CSS和JavaScript库到DOM中
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
showToast({required String msg, Duration toastDuration = const Duration(seconds: 1), DencendToastGravity? gravity, ToastStyle? style}) Future<bool?>
显示Toast消息
override
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Methods

registerWith(Registrar registrar) → void
注册Web平台实现