Displaying an alert popup everytime the Playlist is created or deleted

Signed-off-by: AmbrishRamachandiran <ambrish.r@infosys.com>
This commit is contained in:
AmbrishRamachandiran
2023-07-24 23:22:16 +05:30
parent 8e9c43a209
commit ce1e317113
2 changed files with 10 additions and 0 deletions
+5
View File
@@ -0,0 +1,5 @@
---
'@backstage/plugin-playlist': patch
---
Displaying an alert popup every time the Playlist is created or deleted
@@ -131,6 +131,11 @@ export const EntityPlaylistDialog = (props: EntityPlaylistDialogProps) => {
await playlistApi.addPlaylistEntities(playlistId, [
stringifyEntityRef(entity!),
]);
alertApi.post({
message: `Added playlist '${playlist.name}'`,
severity: 'success',
display: 'transient',
});
navigate(playlistRoute({ playlistId }));
} catch (e) {
alertApi.post({