MCPcopy
hub / github.com/FlowiseAI/Flowise / enqueueSnackbar

Function enqueueSnackbar

packages/ui/src/store/actions.js:28–43  ·  view source on GitHub ↗
(notification)

Source from the content-addressed store, hash-verified

26export const HIDE_CONFIRM = 'HIDE_CONFIRM'
27
28export const enqueueSnackbar = (notification) => {
29 const key = notification.options && notification.options.key
30
31 return {
32 type: ENQUEUE_SNACKBAR,
33 notification: {
34 ...notification,
35 options: {
36 ...notification.options,
37 persist: notification.options?.persist ?? false, // Default: auto-close enabled
38 autoHideDuration: notification.options?.autoHideDuration ?? 5000 // Default auto-close duration: 5 seconds
39 },
40 key: key || new Date().getTime() + Math.random()
41 }
42 }
43}
44
45export const closeSnackbar = (key) => ({
46 type: CLOSE_SNACKBAR,

Callers 15

signOutClickedFunction · 0.90
signOutClickedFunction · 0.90
errorFailedFunction · 0.90
importAllSuccessFunction · 0.90
deleteUserFunction · 0.90
updateUserFunction · 0.90
exportToolFunction · 0.90
addNewToolFunction · 0.90
saveToolFunction · 0.90
deleteToolFunction · 0.90
showSnackbarFunction · 0.90
deleteCredentialFunction · 0.90

Calls 1

getTimeMethod · 0.45

Tested by

no test coverage detected