Private
Public Access
1
0
Files
power-apps-codeapps-blog-part2/node_modules/@fluentui/react-toast/lib/state/vanilla/dismissToast.js

13 lines
343 B
JavaScript

import { EVENTS } from '../constants';
export function dismissToast(toastId, toasterId = undefined, targetDocument) {
const event = new CustomEvent(EVENTS.dismiss, {
bubbles: false,
cancelable: false,
detail: {
toastId,
toasterId
}
});
targetDocument.dispatchEvent(event);
}