Show new cell name in new cell notification
parent
0695904075
commit
334e8dfa27
|
@ -299,7 +299,7 @@ export const addDashboardCellAsync = (
|
||||||
getNewDashboardCell(dashboard, cellType)
|
getNewDashboardCell(dashboard, cellType)
|
||||||
)
|
)
|
||||||
dispatch(addDashboardCell(dashboard, data))
|
dispatch(addDashboardCell(dashboard, data))
|
||||||
dispatch(notify(notifyCellAdded()))
|
dispatch(notify(notifyCellAdded(data.name)))
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.error(error)
|
console.error(error)
|
||||||
dispatch(errorThrown(error))
|
dispatch(errorThrown(error))
|
||||||
|
|
|
@ -412,24 +412,24 @@ export const notifyDashboardDeleted = name => ({
|
||||||
export const notifyDashboardDeleteFailed = (name, errorMessage) =>
|
export const notifyDashboardDeleteFailed = (name, errorMessage) =>
|
||||||
`Failed to delete Dashboard ${name}: ${errorMessage}.`
|
`Failed to delete Dashboard ${name}: ${errorMessage}.`
|
||||||
|
|
||||||
export const notifyCellAdded = () => ({
|
export const notifyCellAdded = name => ({
|
||||||
...defaultSuccessNotification,
|
...defaultSuccessNotification,
|
||||||
icon: 'dash-h',
|
icon: 'dash-h',
|
||||||
duration: 2200,
|
duration: 1900,
|
||||||
message: 'Added "Untitled Cell" to dashboard.',
|
message: `Added "${name}" to dashboard.`,
|
||||||
})
|
})
|
||||||
|
|
||||||
export const notifyCellCloned = name => ({
|
export const notifyCellCloned = name => ({
|
||||||
...defaultSuccessNotification,
|
...defaultSuccessNotification,
|
||||||
icon: 'duplicate',
|
icon: 'duplicate',
|
||||||
duration: 2200,
|
duration: 1900,
|
||||||
message: `Added "${name}" to dashboard.`,
|
message: `Added "${name}" to dashboard.`,
|
||||||
})
|
})
|
||||||
|
|
||||||
export const notifyCellDeleted = name => ({
|
export const notifyCellDeleted = name => ({
|
||||||
...defaultDeletionNotification,
|
...defaultDeletionNotification,
|
||||||
icon: 'dash-h',
|
icon: 'dash-h',
|
||||||
duration: 2200,
|
duration: 1900,
|
||||||
message: `Deleted "${name}" from dashboard.`,
|
message: `Deleted "${name}" from dashboard.`,
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue