码农搬砖工 9018a4f868 xxx
2025-04-23 18:23:41 +08:00

23 lines
392 B
JavaScript

import Toast, { hideToast } from 'tdesign-miniprogram/toast/index';
const useToastBehavior = Behavior({
methods: {
onShowToast(selector, message) {
Toast({
context: this,
selector,
message,
});
},
onHideToast(selector) {
hideToast({
context: this,
selector,
});
},
},
});
export default useToastBehavior;