UI Improvements 14604-ui-improvements
authorPawel Kromplewski <pawel.kromplewski@contractors.roche.com>
Fri, 28 Dec 2018 12:41:47 +0000 (13:41 +0100)
committerPawel Kromplewski <pawel.kromplewski@contractors.roche.com>
Fri, 28 Dec 2018 12:41:47 +0000 (13:41 +0100)
Feature #14604

Arvados-DCO-1.1-Signed-off-by: Pawel Kromplewski <pawel.kromplewski@contractors.roche.com>

31 files changed:
src/store/auth/auth-action-ssh.ts
src/store/collection-panel/collection-panel-action.ts
src/store/collections/collection-move-actions.ts
src/store/collections/collection-partial-copy-actions.ts
src/store/compute-nodes/compute-nodes-actions.ts
src/store/details-panel/details-panel-action.ts
src/store/favorite-panel/favorite-panel-middleware-service.ts
src/store/favorites/favorites-actions.ts
src/store/group-details-panel/group-details-panel-actions.ts
src/store/group-details-panel/group-details-panel-middleware-service.ts
src/store/groups-panel/groups-panel-actions.ts
src/store/groups-panel/groups-panel-middleware-service.ts
src/store/keep-services/keep-services-actions.ts
src/store/link-panel/link-panel-actions.ts
src/store/processes/process-copy-actions.ts
src/store/processes/process-input-actions.ts
src/store/processes/process-move-actions.ts
src/store/processes/process-update-actions.ts
src/store/processes/processes-actions.ts
src/store/project-panel/project-panel-middleware-service.ts
src/store/repositories/repositories-actions.ts
src/store/shared-with-me-panel/shared-with-me-middleware-service.ts
src/store/side-panel/side-panel-action.ts
src/store/trash/trash-actions.ts
src/store/virtual-machines/virtual-machines-actions.ts
src/store/workbench/workbench-actions.ts
src/views-components/context-menu/action-sets/collection-action-set.ts
src/views-components/context-menu/action-sets/collection-resource-action-set.ts
src/views-components/context-menu/action-sets/project-action-set.ts
src/views-components/data-explorer/renderers.tsx
src/views/collection-panel/collection-panel.tsx

index 2c3a27228ef308db847670e24c5a21b3b44ff749..1fbdfdfa63a1b5d49aeb1ff056f3aa22b3c4fe6d 100644 (file)
@@ -6,7 +6,7 @@ import { dialogActions } from "~/store/dialog/dialog-actions";
 import { Dispatch } from "redux";
 import { RootState } from "~/store/store";
 import { ServiceRepository } from "~/services/services";
-import { snackbarActions } from "~/store/snackbar/snackbar-actions";
+import {snackbarActions, SnackbarKind} from "~/store/snackbar/snackbar-actions";
 import { FormErrors, reset, startSubmit, stopSubmit } from "redux-form";
 import { KeyType } from "~/models/ssh-key";
 import {
@@ -54,10 +54,10 @@ export const openSshKeyRemoveDialog = (uuid: string) =>
 
 export const removeSshKey = (uuid: string) =>
     async (dispatch: Dispatch, getState: () => RootState, services: ServiceRepository) => {
-        dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Removing ...' }));
+        dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Removing ...', kind: SnackbarKind.INFO }));
         await services.authorizedKeysService.delete(uuid);
         dispatch(authActions.REMOVE_SSH_KEY(uuid));
-        dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Public Key has been successfully removed.', hideDuration: 2000 }));
+        dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Public Key has been successfully removed.', hideDuration: 2000, kind: SnackbarKind.SUCCESS }));
     };
 
 export const createSshKey = (data: SshKeyCreateFormDialogData) =>
@@ -77,7 +77,8 @@ export const createSshKey = (data: SshKeyCreateFormDialogData) =>
             dispatch(reset(SSH_KEY_CREATE_FORM_NAME));
             dispatch(snackbarActions.OPEN_SNACKBAR({
                 message: "Public key has been successfully created.",
-                hideDuration: 2000
+                hideDuration: 2000,
+                kind: SnackbarKind.SUCCESS
             }));
         } catch (e) {
             const error = getAuthorizedKeysServiceError(e);
index 3b3e34c2b063765a02e2a1b9808ece9ab9aeb75c..919cd9088df45139df5db2379c10377ed73e0f89 100644 (file)
@@ -46,7 +46,7 @@ export const createCollectionTag = (data: TagProperty) =>
                 item.properties[data.key] = data.value;
                 const updatedCollection = await services.collectionService.update(uuid, item);
                 dispatch(resourcesActions.SET_RESOURCES([updatedCollection]));
-                dispatch(snackbarActions.OPEN_SNACKBAR({ message: "Tag has been successfully added.", hideDuration: 2000 }));
+                dispatch(snackbarActions.OPEN_SNACKBAR({ message: "Tag has been successfully added.", hideDuration: 2000, kind: SnackbarKind.SUCCESS }));
                 return updatedCollection;
             }
             return;
@@ -74,7 +74,7 @@ export const deleteCollectionTag = (key: string) =>
                 delete item.properties[key];
                 const updatedCollection = await services.collectionService.update(uuid, item);
                 dispatch(resourcesActions.SET_RESOURCES([updatedCollection]));
-                dispatch(snackbarActions.OPEN_SNACKBAR({ message: "Tag has been successfully deleted.", hideDuration: 2000 }));
+                dispatch(snackbarActions.OPEN_SNACKBAR({ message: "Tag has been successfully deleted.", hideDuration: 2000, kind: SnackbarKind.SUCCESS }));
                 return updatedCollection;
             }
             return;
index aacaf4e66d88cd6e2c8e9eab9e0b8f85173afb75..dc73e5a515bdc9d07d34b1361ba656d98380ab6c 100644 (file)
@@ -8,7 +8,7 @@ import { startSubmit, stopSubmit, initialize, FormErrors } from 'redux-form';
 import { ServiceRepository } from '~/services/services';
 import { RootState } from '~/store/store';
 import { getCommonResourceServiceError, CommonResourceServiceError } from "~/services/common-service/common-resource-service";
-import { snackbarActions } from '~/store/snackbar/snackbar-actions';
+import {snackbarActions, SnackbarKind} from '~/store/snackbar/snackbar-actions';
 import { projectPanelActions } from '~/store/project-panel/project-panel-action';
 import { MoveToFormDialogData } from '~/store/move-to-dialog/move-to-dialog';
 import { resetPickerProjectTree } from '~/store/project-tree-picker/project-tree-picker-actions';
@@ -42,7 +42,7 @@ export const moveCollection = (resource: MoveToFormDialogData) =>
                 dispatch(stopSubmit(COLLECTION_MOVE_FORM_NAME, { ownerUuid: 'A collection with the same name already exists in the target project.' } as FormErrors));
             } else {
                 dispatch(dialogActions.CLOSE_DIALOG({ id: COLLECTION_MOVE_FORM_NAME }));
-                dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Could not move the collection.', hideDuration: 2000 }));
+                dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Could not move the collection.', hideDuration: 2000, kind: SnackbarKind.ERROR }));
             }
             dispatch(progressIndicatorActions.STOP_WORKING(COLLECTION_MOVE_FORM_NAME));
             return;
index ef2c1284fd6ba49d9866d8f3ea3bcdc6f6852387..2597f8d2dde6eceeed35ef669e853a3be701fa0a 100644 (file)
@@ -70,10 +70,10 @@ export const copyCollectionPartial = ({ name, description, projectUuid }: Collec
                     dispatch(stopSubmit(COLLECTION_PARTIAL_COPY_FORM_NAME, { name: 'Collection with this name already exists.' } as FormErrors));
                 } else if (error === CommonResourceServiceError.UNKNOWN) {
                     dispatch(dialogActions.CLOSE_DIALOG({ id: COLLECTION_PARTIAL_COPY_FORM_NAME }));
-                    dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Could not create a copy of collection', hideDuration: 2000 }));
+                    dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Could not create a copy of collection', hideDuration: 2000, kind: SnackbarKind.ERROR }));
                 } else {
                     dispatch(dialogActions.CLOSE_DIALOG({ id: COLLECTION_PARTIAL_COPY_FORM_NAME }));
-                    dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Collection has been copied but may contain incorrect files.', hideDuration: 2000 }));
+                    dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Collection has been copied but may contain incorrect files.', hideDuration: 2000, kind: SnackbarKind.ERROR }));
                 }
                 dispatch(progressIndicatorActions.STOP_WORKING(COLLECTION_PARTIAL_COPY_FORM_NAME));
             }
index f2f6ad0741e6312f7f5e9cd0683288c13ae74d93..7a76c1296b45fbd187b47a5d76c0ea5797a10f23 100644 (file)
@@ -6,7 +6,7 @@ import { Dispatch } from "redux";
 import { RootState } from '~/store/store';
 import { setBreadcrumbs } from '~/store/breadcrumbs/breadcrumbs-actions';
 import { dialogActions } from '~/store/dialog/dialog-actions';
-import { snackbarActions } from '~/store/snackbar/snackbar-actions';
+import {snackbarActions, SnackbarKind} from '~/store/snackbar/snackbar-actions';
 import { navigateToRootProject } from '~/store/navigation/navigation-action';
 import { bindDataExplorerActions } from '~/store/data-explorer/data-explorer-action';
 import { getResource } from '~/store/resources/resources';
@@ -31,7 +31,7 @@ export const loadComputeNodesPanel = () =>
             }
         } else {
             dispatch(navigateToRootProject);
-            dispatch(snackbarActions.OPEN_SNACKBAR({ message: "You don't have permissions to view this page", hideDuration: 2000 }));
+            dispatch(snackbarActions.OPEN_SNACKBAR({ message: "You don't have permissions to view this page", hideDuration: 2000, kind: SnackbarKind.ERROR }));
         }
     };
 
@@ -57,11 +57,11 @@ export const openComputeNodeRemoveDialog = (uuid: string) =>
 
 export const removeComputeNode = (uuid: string) =>
     async (dispatch: Dispatch, getState: () => RootState, services: ServiceRepository) => {
-        dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Removing ...' }));
+        dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Removing ...', kind: SnackbarKind.INFO }));
         try {
             await services.nodeService.delete(uuid);
             dispatch(computeNodesActions.REQUEST_ITEMS());
-            dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Compute node has been successfully removed.', hideDuration: 2000 }));
+            dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Compute node has been successfully removed.', hideDuration: 2000, kind: SnackbarKind.SUCCESS }));
         } catch (e) {
             return;
         }
index 2c742a1f38a3f4e63698019c092dec34935f1079..e13c84f61f45ac63514ca5f528a15d0f27974076 100644 (file)
@@ -12,7 +12,7 @@ import { ServiceRepository } from '~/services/services';
 import { TagProperty } from '~/models/tag';
 import { startSubmit, stopSubmit } from 'redux-form';
 import { resourcesActions } from '~/store/resources/resources-actions';
-import { snackbarActions } from '~/store/snackbar/snackbar-actions';
+import {snackbarActions, SnackbarKind} from '~/store/snackbar/snackbar-actions';
 
 export const SLIDE_TIMEOUT = 500;
 
@@ -42,7 +42,7 @@ export const deleteProjectProperty = (key: string) =>
                 delete project.properties[key];
                 const updatedProject = await services.projectService.update(project.uuid, project);
                 dispatch(resourcesActions.SET_RESOURCES([updatedProject]));
-                dispatch(snackbarActions.OPEN_SNACKBAR({ message: "Property has been successfully deleted.", hideDuration: 2000 }));
+                dispatch(snackbarActions.OPEN_SNACKBAR({ message: "Property has been successfully deleted.", hideDuration: 2000, kind: SnackbarKind.SUCCESS }));
             }
         } catch (e) {
             dispatch(dialogActions.CLOSE_DIALOG({ id: PROJECT_PROPERTIES_FORM_NAME }));
@@ -60,7 +60,7 @@ export const createProjectProperty = (data: TagProperty) =>
                 project.properties[data.key] = data.value;
                 const updatedProject = await services.projectService.update(project.uuid, project);
                 dispatch(resourcesActions.SET_RESOURCES([updatedProject]));
-                dispatch(snackbarActions.OPEN_SNACKBAR({ message: "Property has been successfully added.", hideDuration: 2000 }));
+                dispatch(snackbarActions.OPEN_SNACKBAR({ message: "Property has been successfully added.", hideDuration: 2000, kind: SnackbarKind.SUCCESS }));
                 dispatch(stopSubmit(PROJECT_PROPERTIES_FORM_NAME));
             }
             return;
index 87f49f34f281221da6bb3ea7e33df5b3852d520d..9f80b4766c4d18048e8d2db15b3b5e65a5c89f6d 100644 (file)
@@ -93,7 +93,8 @@ export class FavoritePanelMiddlewareService extends DataExplorerMiddlewareServic
 
 const favoritesPanelDataExplorerIsNotSet = () =>
     snackbarActions.OPEN_SNACKBAR({
-        message: 'Favorites panel is not ready.'
+        message: 'Favorites panel is not ready.',
+        kind: SnackbarKind.ERROR
     });
 
 const couldNotFetchFavoritesContents = () =>
index 5a3001fbc0d352f6992421d9b7fa5c6354b0cfc1..dfa2740ecfdc836f9ce396f950399c7c80622373 100644 (file)
@@ -27,7 +27,8 @@ export const toggleFavorite = (resource: { uuid: string; name: string }) =>
         dispatch(snackbarActions.OPEN_SNACKBAR({
             message: isFavorite
                 ? "Removing from favorites..."
-                : "Adding to favorites..."
+                : "Adding to favorites...",
+            kind: SnackbarKind.INFO
         }));
 
         const promise: any = isFavorite
index 4ad01594477b420f5a105287819d823e0ed9adf3..b73c3bbea9399fb639b5117f45b916f1aa3511b9 100644 (file)
@@ -109,7 +109,7 @@ export const removeGroupMember = (uuid: string) =>
             const group = getResource<GroupResource>(groupUuid)(getState().resources);
             const user = getResource<UserResource>(groupUuid)(getState().resources);
 
-            dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Removing ...' }));
+            dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Removing ...', kind: SnackbarKind.INFO }));
 
             await deleteGroupMember({
                 user: {
index bf424c54812b0a981739bcdcfd4e4eafc22c6eb8..d1a942999c2a6f8803ce1be78cb8e47443ea8225 100644 (file)
@@ -69,7 +69,8 @@ export class GroupDetailsPanelMiddlewareService extends DataExplorerMiddlewareSe
 
 const groupsDetailsPanelDataExplorerIsNotSet = () =>
     snackbarActions.OPEN_SNACKBAR({
-        message: 'Group details panel is not ready.'
+        message: 'Group details panel is not ready.',
+        kind: SnackbarKind.ERROR
     });
 
 const couldNotFetchGroupDetailsContents = () =>
index 8632098ea61b146798ef0df7aca52b2755a7c559..b7cf48054531c3fb988ab19cc5071660e6fe258c 100644 (file)
@@ -44,7 +44,7 @@ export const openGroupAttributes = (uuid: string) =>
 
 export const removeGroup = (uuid: string) =>
     async (dispatch: Dispatch, getState: () => RootState, services: ServiceRepository) => {
-        dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Removing ...' }));
+        dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Removing ...', kind: SnackbarKind.INFO }));
         await services.groupsService.delete(uuid);
         dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Removed.', hideDuration: 2000, kind: SnackbarKind.SUCCESS }));
         dispatch<any>(loadGroupsPanel());
index 7c70666e0c7cb798623fc32f9a9a08b11fc25e65..7a5d93cc6e4ba1502f1efd01bd61bfa332f40196 100644 (file)
@@ -86,7 +86,8 @@ export class GroupsPanelMiddlewareService extends DataExplorerMiddlewareService
 
 const groupsPanelDataExplorerIsNotSet = () =>
     snackbarActions.OPEN_SNACKBAR({
-        message: 'Groups panel is not ready.'
+        message: 'Groups panel is not ready.',
+        kind: SnackbarKind.ERROR
     });
 
 const couldNotFetchFavoritesContents = () =>
index 54a7c3fe87161b6488d0060c576ae7e7dbcd2af5..4eb5fc951ed7e46aacafbe06d362c0c4c3ca0af5 100644 (file)
@@ -9,7 +9,7 @@ import { setBreadcrumbs } from '~/store/breadcrumbs/breadcrumbs-actions';
 import { ServiceRepository } from "~/services/services";
 import { KeepServiceResource } from '~/models/keep-services';
 import { dialogActions } from '~/store/dialog/dialog-actions';
-import { snackbarActions } from '~/store/snackbar/snackbar-actions';
+import {snackbarActions, SnackbarKind} from '~/store/snackbar/snackbar-actions';
 import { navigateToRootProject } from '~/store/navigation/navigation-action';
 
 export const keepServicesActions = unionize({
@@ -35,7 +35,7 @@ export const loadKeepServicesPanel = () =>
             }
         } else {
             dispatch(navigateToRootProject);
-            dispatch(snackbarActions.OPEN_SNACKBAR({ message: "You don't have permissions to view this page", hideDuration: 2000 }));
+            dispatch(snackbarActions.OPEN_SNACKBAR({ message: "You don't have permissions to view this page", hideDuration: 2000, kind: SnackbarKind.ERROR }));
         }
     };
 
@@ -60,11 +60,11 @@ export const openKeepServiceRemoveDialog = (uuid: string) =>
 
 export const removeKeepService = (uuid: string) =>
     async (dispatch: Dispatch, getState: () => RootState, services: ServiceRepository) => {
-        dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Removing ...' }));
+        dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Removing ...', kind: SnackbarKind.INFO }));
         try {
             await services.keepService.delete(uuid);
             dispatch(keepServicesActions.REMOVE_KEEP_SERVICE(uuid));
-            dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Keep service has been successfully removed.', hideDuration: 2000 }));
+            dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Keep service has been successfully removed.', hideDuration: 2000, kind: SnackbarKind.SUCCESS }));
         } catch (e) {
             return;
         }
index 7cbc507342cd3b301035852f71b989a36837d4be..bb9077b9233402ebf084c5b60aa42b6b816bfc19 100644 (file)
@@ -10,7 +10,7 @@ import { setBreadcrumbs } from '~/store/breadcrumbs/breadcrumbs-actions';
 import { dialogActions } from '~/store/dialog/dialog-actions';
 import { LinkResource } from '~/models/link';
 import { getResource } from '~/store/resources/resources';
-import { snackbarActions } from '~/store/snackbar/snackbar-actions';
+import {snackbarActions, SnackbarKind} from '~/store/snackbar/snackbar-actions';
 
 export const LINK_PANEL_ID = "linkPanelId";
 export const linkPanelActions = bindDataExplorerActions(LINK_PANEL_ID);
@@ -46,11 +46,11 @@ export const openLinkRemoveDialog = (uuid: string) =>
 
 export const removeLink = (uuid: string) =>
     async (dispatch: Dispatch, getState: () => RootState, services: ServiceRepository) => {
-        dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Removing ...' }));
+        dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Removing ...', kind: SnackbarKind.INFO }));
         try {
             await services.linkService.delete(uuid);
             dispatch(linkPanelActions.REQUEST_ITEMS());
-            dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Link has been successfully removed.', hideDuration: 2000 }));
+            dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Link has been successfully removed.', hideDuration: 2000, kind: SnackbarKind.SUCCESS }));
         } catch (e) {
             return;
         }
index 01387852107c3224bb6c348aca9b05189d4441c4..729d6a13de62369cfa058eb50351aa9ffe9a7489 100644 (file)
@@ -10,7 +10,7 @@ import { RootState } from '~/store/store';
 import { ServiceRepository } from '~/services/services';
 import { CopyFormDialogData } from '~/store/copy-dialog/copy-dialog';
 import { getProcess } from '~/store/processes/process';
-import { snackbarActions } from '~/store/snackbar/snackbar-actions';
+import {snackbarActions, SnackbarKind} from '~/store/snackbar/snackbar-actions';
 import { initProjectsTreePicker } from '~/store/tree-picker/tree-picker-actions';
 
 export const PROCESS_COPY_FORM_NAME = 'processCopyFormName';
@@ -25,7 +25,7 @@ export const openCopyProcessDialog = (resource: { name: string, uuid: string })
             dispatch<any>(initialize(PROCESS_COPY_FORM_NAME, initialData));
             dispatch(dialogActions.OPEN_DIALOG({ id: PROCESS_COPY_FORM_NAME, data: {} }));
         } else {
-            dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Process not found', hideDuration: 2000 }));
+            dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Process not found', hideDuration: 2000, kind: SnackbarKind.ERROR }));
         }
     };
 
index b35081c19e656d63288a00a7d8ce937caeb68853..98899a42fb8f6c7cee3b4b0c63382629b9da63b5 100644 (file)
@@ -6,7 +6,7 @@ import { dialogActions } from '~/store/dialog/dialog-actions';
 import { RootState } from '~/store/store';
 import { Dispatch } from 'redux';
 import { getProcess } from '~/store/processes/process';
-import { snackbarActions } from '~/store/snackbar/snackbar-actions';
+import {snackbarActions, SnackbarKind} from '~/store/snackbar/snackbar-actions';
 
 export const PROCESS_INPUT_DIALOG_NAME = 'processInputDialog';
 
@@ -18,7 +18,7 @@ export const openProcessInputDialog = (processUuid: string) =>
             if (data && data.containerRequest.mounts.varLibCwlWorkflowJson && data.containerRequest.mounts.varLibCwlWorkflowJson.content.graph[1].inputs.length > 0) {
                 dispatch(dialogActions.OPEN_DIALOG({ id: PROCESS_INPUT_DIALOG_NAME, data }));
             } else {
-                dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'There are no inputs in this process!' }));
+                dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'There are no inputs in this process!', kind: SnackbarKind.ERROR }));
             }
         }
     }; 
\ No newline at end of file
index dcf97185c3a1ebca03bfaccfdbfbde16db80d83f..475b4c1fb80c393aa43f70321de579244463a051 100644 (file)
@@ -8,7 +8,7 @@ import { startSubmit, stopSubmit, initialize, FormErrors } from 'redux-form';
 import { ServiceRepository } from '~/services/services';
 import { RootState } from '~/store/store';
 import { getCommonResourceServiceError, CommonResourceServiceError } from "~/services/common-service/common-resource-service";
-import { snackbarActions } from '~/store/snackbar/snackbar-actions';
+import {snackbarActions, SnackbarKind} from '~/store/snackbar/snackbar-actions';
 import { MoveToFormDialogData } from '~/store/move-to-dialog/move-to-dialog';
 import { resetPickerProjectTree } from '~/store/project-tree-picker/project-tree-picker-actions';
 import { projectPanelActions } from '~/store/project-panel/project-panel-action';
@@ -26,7 +26,7 @@ export const openMoveProcessDialog = (resource: { name: string, uuid: string })
             dispatch(initialize(PROCESS_MOVE_FORM_NAME, resource));
             dispatch(dialogActions.OPEN_DIALOG({ id: PROCESS_MOVE_FORM_NAME, data: {} }));
         } else {
-            dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Process not found', hideDuration: 2000 }));
+            dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Process not found', hideDuration: 2000, kind: SnackbarKind.ERROR }));
         }
     };
 
@@ -45,7 +45,7 @@ export const moveProcess = (resource: MoveToFormDialogData) =>
                 dispatch(stopSubmit(PROCESS_MOVE_FORM_NAME, { ownerUuid: 'A process with the same name already exists in the target project.' } as FormErrors));
             } else {
                 dispatch(dialogActions.CLOSE_DIALOG({ id: PROCESS_MOVE_FORM_NAME }));
-                dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Could not move the process.', hideDuration: 2000 }));
+                dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Could not move the process.', hideDuration: 2000, kind: SnackbarKind.ERROR }));
             }
             return;
         }
index 1d6d95bb80cc2a9344efb162297b0bf95fd69c30..f8d78bc60a0a94930afa8689bf059b85f055b92f 100644 (file)
@@ -10,7 +10,7 @@ import { getCommonResourceServiceError, CommonResourceServiceError } from "~/ser
 import { ServiceRepository } from "~/services/services";
 import { getProcess } from '~/store/processes/process';
 import { projectPanelActions } from '~/store/project-panel/project-panel-action';
-import { snackbarActions } from '~/store/snackbar/snackbar-actions';
+import {snackbarActions, SnackbarKind} from '~/store/snackbar/snackbar-actions';
 
 export interface ProcessUpdateFormDialogData {
     uuid: string;
@@ -27,7 +27,7 @@ export const openProcessUpdateDialog = (resource: ProcessUpdateFormDialogData) =
             dispatch(initialize(PROCESS_UPDATE_FORM_NAME, { ...resource, name: process.containerRequest.name }));
             dispatch(dialogActions.OPEN_DIALOG({ id: PROCESS_UPDATE_FORM_NAME, data: {} }));
         } else {
-            dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Process not found', hideDuration: 2000 }));
+            dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Process not found', hideDuration: 2000, kind: SnackbarKind.ERROR }));
         }
     };
 
@@ -45,7 +45,7 @@ export const updateProcess = (resource: ProcessUpdateFormDialogData) =>
                 dispatch(stopSubmit(PROCESS_UPDATE_FORM_NAME, { name: 'Process with the same name already exists.' } as FormErrors));
             } else {
                 dispatch(dialogActions.CLOSE_DIALOG({ id: PROCESS_UPDATE_FORM_NAME }));
-                dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Could not update the process.', hideDuration: 2000 }));
+                dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Could not update the process.', hideDuration: 2000, kind: SnackbarKind.ERROR }));
             }
             return;
         }
index f9f5ef728beff7659ff2b56e96aed93ba6d6736a..fa81da9fc344e2f9e3e52545f7ff19e11b8e3f27 100644 (file)
@@ -10,7 +10,7 @@ import { FilterBuilder } from '~/services/api/filter-builder';
 import { ContainerRequestResource } from '~/models/container-request';
 import { Process } from './process';
 import { dialogActions } from '~/store/dialog/dialog-actions';
-import { snackbarActions } from '~/store/snackbar/snackbar-actions';
+import {snackbarActions, SnackbarKind} from '~/store/snackbar/snackbar-actions';
 import { projectPanelActions } from '~/store/project-panel/project-panel-action';
 
 export const loadProcess = (containerRequestUuid: string) =>
@@ -75,10 +75,10 @@ export const REMOVE_PROCESS_DIALOG = 'removeProcessDialog';
 
 export const removeProcessPermanently = (uuid: string) =>
     async (dispatch: Dispatch, getState: () => RootState, services: ServiceRepository) =>{
-        dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Removing ...' }));
+        dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Removing ...', kind: SnackbarKind.INFO }));
         await services.containerRequestService.delete(uuid);
         dispatch(projectPanelActions.REQUEST_ITEMS());
-        dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Removed.', hideDuration: 2000 }));
+        dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Removed.', hideDuration: 2000, kind: SnackbarKind.SUCCESS }));
     };
         
 
index 58f158772240019b1b3a9873546cfd7b61e39ed6..d0964c8f7ef89351653a93aa5cd7b4813e776932 100644 (file)
@@ -155,7 +155,8 @@ export const getOrder = (dataExplorer: DataExplorer) => {
 
 const projectPanelCurrentUuidIsNotSet = () =>
     snackbarActions.OPEN_SNACKBAR({
-        message: 'Project panel is not opened.'
+        message: 'Project panel is not opened.',
+        kind: SnackbarKind.ERROR
     });
 
 const couldNotFetchProjectContents = () =>
@@ -166,5 +167,6 @@ const couldNotFetchProjectContents = () =>
 
 const projectPanelDataExplorerIsNotSet = () =>
     snackbarActions.OPEN_SNACKBAR({
-        message: 'Project panel is not ready.'
+        message: 'Project panel is not ready.',
+        kind: SnackbarKind.ERROR
     });
index f2f06e805def51d0843fdecf2d91f39c785779e0..3b77defe1a3f45730df3686b0d8eeeb9159568c3 100644 (file)
@@ -82,7 +82,7 @@ export const openRemoveRepositoryDialog = (uuid: string) =>
 
 export const removeRepository = (uuid: string) =>
     async (dispatch: Dispatch, getState: () => RootState, services: ServiceRepository) => {
-        dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Removing ...' }));
+        dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Removing ...', kind: SnackbarKind.INFO }));
         await services.repositoriesService.delete(uuid);
         dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Removed.', hideDuration: 2000, kind: SnackbarKind.SUCCESS }));
         dispatch<any>(loadRepositoriesData());
index 9e76d46da7a30ef8f0b782b8bf701fbb1e47487e..551e279603ae63b1fbf31e7cfcf51d810c906534 100644 (file)
@@ -10,7 +10,7 @@ import { getDataExplorer, DataExplorer } from '~/store/data-explorer/data-explor
 import { updateFavorites } from '~/store/favorites/favorites-actions';
 import { updateResources } from '~/store/resources/resources-actions';
 import { loadMissingProcessesInformation, getFilters } from '~/store/project-panel/project-panel-middleware-service';
-import { snackbarActions } from '~/store/snackbar/snackbar-actions';
+import {snackbarActions, SnackbarKind} from '~/store/snackbar/snackbar-actions';
 import { sharedWithMePanelActions } from './shared-with-me-panel-actions';
 import { ListResults } from '~/services/common-service/common-service';
 import { GroupContentsResource, GroupContentsResourcePrefix } from '~/services/groups-service/groups-service';
@@ -82,5 +82,6 @@ export const setItems = (listResults: ListResults<GroupContentsResource>) =>
 
 const couldNotFetchSharedItems = () =>
     snackbarActions.OPEN_SNACKBAR({
-        message: 'Could not fetch shared items.'
+        message: 'Could not fetch shared items.',
+        kind: SnackbarKind.ERROR
     });
index fd08ee1319d5b1550bd278591df4997d7d7f247a..6d3e474696cd92c900f36c88fe3cc19ddb952a93 100644 (file)
@@ -5,7 +5,7 @@
 import { Dispatch } from 'redux';
 import { isSidePanelTreeCategory, SidePanelTreeCategory } from '~/store/side-panel-tree/side-panel-tree-actions';
 import { navigateToFavorites, navigateTo, navigateToTrash, navigateToSharedWithMe, navigateToWorkflows } from '../navigation/navigation-action';
-import { snackbarActions } from '~/store/snackbar/snackbar-actions';
+import {snackbarActions, SnackbarKind} from '~/store/snackbar/snackbar-actions';
 
 export const navigateFromSidePanel = (id: string) =>
     (dispatch: Dispatch) => {
@@ -35,4 +35,5 @@ const sidePanelTreeCategoryNotAvailable = (id: string) =>
     snackbarActions.OPEN_SNACKBAR({
         message: `${id} not available`,
         hideDuration: 3000,
+        kind: SnackbarKind.ERROR
     });
index 92d01582ab1b6cb3db8dcd3c2622636559a4269b..693a0ece7e9197a5ff494583cee4660ebd7f2a8d 100644 (file)
@@ -17,7 +17,7 @@ export const toggleProjectTrashed = (uuid: string, ownerUuid: string, isTrashed:
     async (dispatch: Dispatch, getState: () => RootState, services: ServiceRepository): Promise<any> => {
         try {
             if (isTrashed) {
-                dispatch(snackbarActions.OPEN_SNACKBAR({ message: "Restoring from trash..." }));
+                dispatch(snackbarActions.OPEN_SNACKBAR({ message: "Restoring from trash...", kind: SnackbarKind.INFO }));
                 await services.groupsService.untrash(uuid);
                 dispatch<any>(activateSidePanelTreeItem(uuid));
                 dispatch(trashPanelActions.REQUEST_ITEMS());
@@ -27,7 +27,7 @@ export const toggleProjectTrashed = (uuid: string, ownerUuid: string, isTrashed:
                     kind: SnackbarKind.SUCCESS
                 }));
             } else {
-                dispatch(snackbarActions.OPEN_SNACKBAR({ message: "Moving to trash..." }));
+                dispatch(snackbarActions.OPEN_SNACKBAR({ message: "Moving to trash...", kind: SnackbarKind.INFO }));
                 await services.groupsService.trash(uuid);
                 dispatch<any>(loadSidePanelTreeProjects(ownerUuid));
                 dispatch(snackbarActions.OPEN_SNACKBAR({
@@ -49,7 +49,7 @@ export const toggleCollectionTrashed = (uuid: string, isTrashed: boolean) =>
         try {
             if (isTrashed) {
                 const { location } = getState().router;
-                dispatch(snackbarActions.OPEN_SNACKBAR({ message: "Restoring from trash..." }));
+                dispatch(snackbarActions.OPEN_SNACKBAR({ message: "Restoring from trash...", kind: SnackbarKind.INFO }));
                 await services.collectionService.untrash(uuid);
                 if (matchCollectionRoute(location ? location.pathname : '')) {
                     dispatch(navigateToTrash);
@@ -61,7 +61,7 @@ export const toggleCollectionTrashed = (uuid: string, isTrashed: boolean) =>
                     kind: SnackbarKind.SUCCESS
                 }));
             } else {
-                dispatch(snackbarActions.OPEN_SNACKBAR({ message: "Moving to trash..." }));
+                dispatch(snackbarActions.OPEN_SNACKBAR({ message: "Moving to trash...", kind: SnackbarKind.INFO }));
                 await services.collectionService.trash(uuid);
                 dispatch(projectPanelActions.REQUEST_ITEMS());
                 dispatch(snackbarActions.OPEN_SNACKBAR({
index 1e9825c1cdcbaf917e120b60af685342d6283ddc..625649593055b9318d4cde4389fd3f5e7c8de66e 100644 (file)
@@ -40,7 +40,7 @@ export const openAdminVirtualMachines = () =>
             dispatch<any>(navigateToAdminVirtualMachines);
         } else {
             dispatch<any>(navigateToRootProject);
-            dispatch(snackbarActions.OPEN_SNACKBAR({ message: "You don't have permissions to view this page", hideDuration: 2000 }));
+            dispatch(snackbarActions.OPEN_SNACKBAR({ message: "You don't have permissions to view this page", hideDuration: 2000, kind: SnackbarKind.ERROR }));
         }
     };
 
@@ -101,7 +101,7 @@ export const openRemoveVirtualMachineDialog = (uuid: string) =>
 
 export const removeVirtualMachine = (uuid: string) =>
     async (dispatch: Dispatch, getState: () => RootState, services: ServiceRepository) => {
-        dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Removing ...' }));
+        dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Removing ...', kind: SnackbarKind.INFO }));
         await services.virtualMachineService.delete(uuid);
         dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Removed.', hideDuration: 2000, kind: SnackbarKind.SUCCESS }));
         dispatch<any>(loadVirtualMachinesAdminData());
index 46ab1f59e9825bf712fc9425c27b78b7369d80a3..46598bde085a5a282e702dcf0ba410a551fbe441 100644 (file)
@@ -182,7 +182,8 @@ export const createProject = (data: projectCreateActions.ProjectCreateFormDialog
         if (newProject) {
             dispatch(snackbarActions.OPEN_SNACKBAR({
                 message: "Project has been successfully created.",
-                hideDuration: 2000
+                hideDuration: 2000,
+                kind: SnackbarKind.SUCCESS
             }));
             await dispatch<any>(loadSidePanelTreeProjects(newProject.ownerUuid));
             dispatch<any>(reloadProjectMatchingUuid([newProject.ownerUuid]));
@@ -196,14 +197,14 @@ export const moveProject = (data: MoveToFormDialogData) =>
             const oldOwnerUuid = oldProject ? oldProject.ownerUuid : '';
             const movedProject = await dispatch<any>(projectMoveActions.moveProject(data));
             if (movedProject) {
-                dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Project has been moved', hideDuration: 2000 }));
+                dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Project has been moved', hideDuration: 2000, kind: SnackbarKind.SUCCESS }));
                 if (oldProject) {
                     await dispatch<any>(loadSidePanelTreeProjects(oldProject.ownerUuid));
                 }
                 dispatch<any>(reloadProjectMatchingUuid([oldOwnerUuid, movedProject.ownerUuid, movedProject.uuid]));
             }
         } catch (e) {
-            dispatch(snackbarActions.OPEN_SNACKBAR({ message: e.message, hideDuration: 2000 }));
+            dispatch(snackbarActions.OPEN_SNACKBAR({ message: e.message, hideDuration: 2000, kind: SnackbarKind.ERROR }));
         }
     };
 
@@ -213,7 +214,8 @@ export const updateProject = (data: projectUpdateActions.ProjectUpdateFormDialog
         if (updatedProject) {
             dispatch(snackbarActions.OPEN_SNACKBAR({
                 message: "Project has been successfully updated.",
-                hideDuration: 2000
+                hideDuration: 2000,
+                kind: SnackbarKind.SUCCESS
             }));
             await dispatch<any>(loadSidePanelTreeProjects(updatedProject.ownerUuid));
             dispatch<any>(reloadProjectMatchingUuid([updatedProject.ownerUuid, updatedProject.uuid]));
@@ -259,7 +261,8 @@ export const createCollection = (data: collectionCreateActions.CollectionCreateF
         if (collection) {
             dispatch(snackbarActions.OPEN_SNACKBAR({
                 message: "Collection has been successfully created.",
-                hideDuration: 2000
+                hideDuration: 2000,
+                kind: SnackbarKind.SUCCESS
             }));
             dispatch<any>(updateResources([collection]));
             dispatch<any>(reloadProjectMatchingUuid([collection.ownerUuid]));
@@ -272,7 +275,8 @@ export const updateCollection = (data: collectionUpdateActions.CollectionUpdateF
         if (collection) {
             dispatch(snackbarActions.OPEN_SNACKBAR({
                 message: "Collection has been successfully updated.",
-                hideDuration: 2000
+                hideDuration: 2000,
+                kind: SnackbarKind.SUCCESS
             }));
             dispatch<any>(updateResources([collection]));
             dispatch<any>(reloadProjectMatchingUuid([collection.ownerUuid]));
@@ -306,7 +310,7 @@ export const moveCollection = (data: MoveToFormDialogData) =>
             dispatch<any>(reloadProjectMatchingUuid([collection.ownerUuid]));
             dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Collection has been moved.', hideDuration: 2000, kind: SnackbarKind.SUCCESS }));
         } catch (e) {
-            dispatch(snackbarActions.OPEN_SNACKBAR({ message: e.message, hideDuration: 2000 }));
+            dispatch(snackbarActions.OPEN_SNACKBAR({ message: e.message, hideDuration: 2000, kind: SnackbarKind.ERROR }));
         }
     };
 
@@ -327,13 +331,14 @@ export const updateProcess = (data: processUpdateActions.ProcessUpdateFormDialog
             if (process) {
                 dispatch(snackbarActions.OPEN_SNACKBAR({
                     message: "Process has been successfully updated.",
-                    hideDuration: 2000
+                    hideDuration: 2000,
+                    kind: SnackbarKind.SUCCESS
                 }));
                 dispatch<any>(updateResources([process]));
                 dispatch<any>(reloadProjectMatchingUuid([process.ownerUuid]));
             }
         } catch (e) {
-            dispatch(snackbarActions.OPEN_SNACKBAR({ message: e.message, hideDuration: 2000 }));
+            dispatch(snackbarActions.OPEN_SNACKBAR({ message: e.message, hideDuration: 2000, kind: SnackbarKind.ERROR }));
         }
     };
 
@@ -343,9 +348,9 @@ export const moveProcess = (data: MoveToFormDialogData) =>
             const process = await dispatch<any>(processMoveActions.moveProcess(data));
             dispatch<any>(updateResources([process]));
             dispatch<any>(reloadProjectMatchingUuid([process.ownerUuid]));
-            dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Process has been moved.', hideDuration: 2000 }));
+            dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Process has been moved.', hideDuration: 2000, kind: SnackbarKind.SUCCESS }));
         } catch (e) {
-            dispatch(snackbarActions.OPEN_SNACKBAR({ message: e.message, hideDuration: 2000 }));
+            dispatch(snackbarActions.OPEN_SNACKBAR({ message: e.message, hideDuration: 2000, kind: SnackbarKind.ERROR }));
         }
     };
 
@@ -355,9 +360,9 @@ export const copyProcess = (data: CopyFormDialogData) =>
             const process = await dispatch<any>(processCopyActions.copyProcess(data));
             dispatch<any>(updateResources([process]));
             dispatch<any>(reloadProjectMatchingUuid([process.ownerUuid]));
-            dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Process has been copied.', hideDuration: 2000 }));
+            dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Process has been copied.', hideDuration: 2000, kind: SnackbarKind.SUCCESS }));
         } catch (e) {
-            dispatch(snackbarActions.OPEN_SNACKBAR({ message: e.message, hideDuration: 2000 }));
+            dispatch(snackbarActions.OPEN_SNACKBAR({ message: e.message, hideDuration: 2000, kind: SnackbarKind.ERROR }));
         }
     };
 
@@ -372,15 +377,18 @@ export const loadProcessLog = (uuid: string) =>
 
 export const resourceIsNotLoaded = (uuid: string) =>
     snackbarActions.OPEN_SNACKBAR({
-        message: `Resource identified by ${uuid} is not loaded.`
+        message: `Resource identified by ${uuid} is not loaded.`,
+        kind: SnackbarKind.ERROR
     });
 
 export const userIsNotAuthenticated = snackbarActions.OPEN_SNACKBAR({
-    message: 'User is not authenticated'
+    message: 'User is not authenticated',
+    kind: SnackbarKind.ERROR
 });
 
 export const couldNotLoadUser = snackbarActions.OPEN_SNACKBAR({
-    message: 'Could not load user'
+    message: 'Could not load user',
+    kind: SnackbarKind.ERROR
 });
 
 export const reloadProjectMatchingUuid = (matchingUuids: string[]) =>
index 9d26fad2ff86a7659b90d1dfdd21b2e679576208..d6095d10ce4b2ce0a8b64aa56ab59e2aa0ebbe1b 100644 (file)
@@ -40,12 +40,6 @@ export const collectionActionSet: ContextMenuActionSet = [[
             });
         }
     },
-    {
-        component: ToggleTrashAction,
-        execute: (dispatch, resource) => {
-            dispatch<any>(toggleCollectionTrashed(resource.uuid, resource.isTrashed!!));
-        }
-    },
     {
         icon: MoveToIcon,
         name: "Move to",
@@ -79,7 +73,13 @@ export const collectionActionSet: ContextMenuActionSet = [[
         execute: (dispatch, resource) => {
             dispatch<any>(openAdvancedTabDialog(resource.uuid));
         }
-    }
+    },
+    {
+        component: ToggleTrashAction,
+        execute: (dispatch, resource) => {
+            dispatch<any>(toggleCollectionTrashed(resource.uuid, resource.isTrashed!!));
+        }
+    },
     // {
     //     icon: RemoveIcon,
     //     name: "Remove",
index 7730b1453812f730aab765254275298ab14e5bda..4b1d8fd84400697202efaeb6c0476ddba77e0d9b 100644 (file)
@@ -40,12 +40,6 @@ export const collectionResourceActionSet: ContextMenuActionSet = [[
             });
         }
     },
-    {
-        component: ToggleTrashAction,
-        execute: (dispatch, resource) => {
-            dispatch<any>(toggleCollectionTrashed(resource.uuid, resource.isTrashed!!));
-        }
-    },
     {
         icon: MoveToIcon,
         name: "Move to",
@@ -73,7 +67,13 @@ export const collectionResourceActionSet: ContextMenuActionSet = [[
         execute: (dispatch, resource) => {
             dispatch<any>(openAdvancedTabDialog(resource.uuid));
         }
-    }
+    },
+    {
+        component: ToggleTrashAction,
+        execute: (dispatch, resource) => {
+            dispatch<any>(toggleCollectionTrashed(resource.uuid, resource.isTrashed!!));
+        }
+    },
     // {
     //     icon: RemoveIcon,
     //     name: "Remove",
index 8c81e3bd1996633ff39eca407e3547a6de0f3cf3..660d7ea03f05f277cecb4f3824a53d4741d3a467 100644 (file)
@@ -47,12 +47,6 @@ export const projectActionSet: ContextMenuActionSet = [[
             });
         }
     },
-    {
-        component: ToggleTrashAction,
-        execute: (dispatch, resource) => {
-            dispatch<any>(toggleProjectTrashed(resource.uuid, resource.ownerUuid, resource.isTrashed!!));
-        }
-    },
     {
         icon: MoveToIcon,
         name: "Move to",
@@ -81,4 +75,10 @@ export const projectActionSet: ContextMenuActionSet = [[
             dispatch<any>(openAdvancedTabDialog(resource.uuid));
         }
     },
+    {
+        component: ToggleTrashAction,
+        execute: (dispatch, resource) => {
+            dispatch<any>(toggleProjectTrashed(resource.uuid, resource.ownerUuid, resource.isTrashed!!));
+        }
+    },
 ]];
index ce4d430fd18597a0c4af04925eb31fa9a636dd77..bb3f4e10ed1ab5b2b7fe5c305befa9bf920735c5 100644 (file)
@@ -33,7 +33,7 @@ const renderName = (item: { name: string; uuid: string, kind: string }) =>
             {renderIcon(item)}
         </Grid>
         <Grid item>
-            <Typography color="primary" style={{ width: '450px' }}>
+            <Typography color="primary" style={{ width: 'auto' }}>
                 {item.name}
             </Typography>
         </Grid>
index 41a685f3283667a3fc5d39b60ccf18e6bc7a2c40..4124344d3f3311129d1320541352221a11416df1 100644 (file)
@@ -18,7 +18,7 @@ import { CollectionPanelFiles } from '~/views-components/collection-panel-files/
 import * as CopyToClipboard from 'react-copy-to-clipboard';
 import { CollectionTagForm } from './collection-tag-form';
 import { deleteCollectionTag, navigateToProcess } from '~/store/collection-panel/collection-panel-action';
-import { snackbarActions } from '~/store/snackbar/snackbar-actions';
+import {snackbarActions, SnackbarKind} from '~/store/snackbar/snackbar-actions';
 import { getResource } from '~/store/resources/resources';
 import { openContextMenu } from '~/store/context-menu/context-menu-actions';
 import { ContextMenuKind } from '~/views-components/context-menu/context-menu';
@@ -169,7 +169,8 @@ export const CollectionPanel = withStyles(styles)(
             onCopy = () => {
                 this.props.dispatch(snackbarActions.OPEN_SNACKBAR({
                     message: "Uuid has been copied",
-                    hideDuration: 2000
+                    hideDuration: 2000,
+                    kind: SnackbarKind.SUCCESS
                 }));
             }
         }