[ARVADOS-WORKBENCH2] created: 1.3.0-247-gfa9b3ce4
Git user
git at public.curoverse.com
Fri Dec 28 07:41:57 EST 2018
at fa9b3ce44a3a9315207852d1f182000a6166f9e9 (commit)
commit fa9b3ce44a3a9315207852d1f182000a6166f9e9
Author: Pawel Kromplewski <pawel.kromplewski at contractors.roche.com>
Date: Fri Dec 28 13:41:47 2018 +0100
UI Improvements
Feature #14604
Arvados-DCO-1.1-Signed-off-by: Pawel Kromplewski <pawel.kromplewski at contractors.roche.com>
diff --git a/src/store/auth/auth-action-ssh.ts b/src/store/auth/auth-action-ssh.ts
index 2c3a2722..1fbdfdfa 100644
--- a/src/store/auth/auth-action-ssh.ts
+++ b/src/store/auth/auth-action-ssh.ts
@@ -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);
diff --git a/src/store/collection-panel/collection-panel-action.ts b/src/store/collection-panel/collection-panel-action.ts
index 3b3e34c2..919cd908 100644
--- a/src/store/collection-panel/collection-panel-action.ts
+++ b/src/store/collection-panel/collection-panel-action.ts
@@ -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;
diff --git a/src/store/collections/collection-move-actions.ts b/src/store/collections/collection-move-actions.ts
index aacaf4e6..dc73e5a5 100644
--- a/src/store/collections/collection-move-actions.ts
+++ b/src/store/collections/collection-move-actions.ts
@@ -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;
diff --git a/src/store/collections/collection-partial-copy-actions.ts b/src/store/collections/collection-partial-copy-actions.ts
index ef2c1284..2597f8d2 100644
--- a/src/store/collections/collection-partial-copy-actions.ts
+++ b/src/store/collections/collection-partial-copy-actions.ts
@@ -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));
}
diff --git a/src/store/compute-nodes/compute-nodes-actions.ts b/src/store/compute-nodes/compute-nodes-actions.ts
index f2f6ad07..7a76c129 100644
--- a/src/store/compute-nodes/compute-nodes-actions.ts
+++ b/src/store/compute-nodes/compute-nodes-actions.ts
@@ -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;
}
diff --git a/src/store/details-panel/details-panel-action.ts b/src/store/details-panel/details-panel-action.ts
index 2c742a1f..e13c84f6 100644
--- a/src/store/details-panel/details-panel-action.ts
+++ b/src/store/details-panel/details-panel-action.ts
@@ -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;
diff --git a/src/store/favorite-panel/favorite-panel-middleware-service.ts b/src/store/favorite-panel/favorite-panel-middleware-service.ts
index 87f49f34..9f80b476 100644
--- a/src/store/favorite-panel/favorite-panel-middleware-service.ts
+++ b/src/store/favorite-panel/favorite-panel-middleware-service.ts
@@ -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 = () =>
diff --git a/src/store/favorites/favorites-actions.ts b/src/store/favorites/favorites-actions.ts
index 5a3001fb..dfa2740e 100644
--- a/src/store/favorites/favorites-actions.ts
+++ b/src/store/favorites/favorites-actions.ts
@@ -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
diff --git a/src/store/group-details-panel/group-details-panel-actions.ts b/src/store/group-details-panel/group-details-panel-actions.ts
index 4ad01594..b73c3bbe 100644
--- a/src/store/group-details-panel/group-details-panel-actions.ts
+++ b/src/store/group-details-panel/group-details-panel-actions.ts
@@ -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: {
diff --git a/src/store/group-details-panel/group-details-panel-middleware-service.ts b/src/store/group-details-panel/group-details-panel-middleware-service.ts
index bf424c54..d1a94299 100644
--- a/src/store/group-details-panel/group-details-panel-middleware-service.ts
+++ b/src/store/group-details-panel/group-details-panel-middleware-service.ts
@@ -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 = () =>
diff --git a/src/store/groups-panel/groups-panel-actions.ts b/src/store/groups-panel/groups-panel-actions.ts
index 8632098e..b7cf4805 100644
--- a/src/store/groups-panel/groups-panel-actions.ts
+++ b/src/store/groups-panel/groups-panel-actions.ts
@@ -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());
diff --git a/src/store/groups-panel/groups-panel-middleware-service.ts b/src/store/groups-panel/groups-panel-middleware-service.ts
index 7c70666e..7a5d93cc 100644
--- a/src/store/groups-panel/groups-panel-middleware-service.ts
+++ b/src/store/groups-panel/groups-panel-middleware-service.ts
@@ -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 = () =>
diff --git a/src/store/keep-services/keep-services-actions.ts b/src/store/keep-services/keep-services-actions.ts
index 54a7c3fe..4eb5fc95 100644
--- a/src/store/keep-services/keep-services-actions.ts
+++ b/src/store/keep-services/keep-services-actions.ts
@@ -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;
}
diff --git a/src/store/link-panel/link-panel-actions.ts b/src/store/link-panel/link-panel-actions.ts
index 7cbc5073..bb9077b9 100644
--- a/src/store/link-panel/link-panel-actions.ts
+++ b/src/store/link-panel/link-panel-actions.ts
@@ -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;
}
diff --git a/src/store/processes/process-copy-actions.ts b/src/store/processes/process-copy-actions.ts
index 01387852..729d6a13 100644
--- a/src/store/processes/process-copy-actions.ts
+++ b/src/store/processes/process-copy-actions.ts
@@ -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 }));
}
};
diff --git a/src/store/processes/process-input-actions.ts b/src/store/processes/process-input-actions.ts
index b35081c1..98899a42 100644
--- a/src/store/processes/process-input-actions.ts
+++ b/src/store/processes/process-input-actions.ts
@@ -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
diff --git a/src/store/processes/process-move-actions.ts b/src/store/processes/process-move-actions.ts
index dcf97185..475b4c1f 100644
--- a/src/store/processes/process-move-actions.ts
+++ b/src/store/processes/process-move-actions.ts
@@ -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;
}
diff --git a/src/store/processes/process-update-actions.ts b/src/store/processes/process-update-actions.ts
index 1d6d95bb..f8d78bc6 100644
--- a/src/store/processes/process-update-actions.ts
+++ b/src/store/processes/process-update-actions.ts
@@ -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;
}
diff --git a/src/store/processes/processes-actions.ts b/src/store/processes/processes-actions.ts
index f9f5ef72..fa81da9f 100644
--- a/src/store/processes/processes-actions.ts
+++ b/src/store/processes/processes-actions.ts
@@ -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 }));
};
diff --git a/src/store/project-panel/project-panel-middleware-service.ts b/src/store/project-panel/project-panel-middleware-service.ts
index 58f15877..d0964c8f 100644
--- a/src/store/project-panel/project-panel-middleware-service.ts
+++ b/src/store/project-panel/project-panel-middleware-service.ts
@@ -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
});
diff --git a/src/store/repositories/repositories-actions.ts b/src/store/repositories/repositories-actions.ts
index f2f06e80..3b77defe 100644
--- a/src/store/repositories/repositories-actions.ts
+++ b/src/store/repositories/repositories-actions.ts
@@ -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());
diff --git a/src/store/shared-with-me-panel/shared-with-me-middleware-service.ts b/src/store/shared-with-me-panel/shared-with-me-middleware-service.ts
index 9e76d46d..551e2796 100644
--- a/src/store/shared-with-me-panel/shared-with-me-middleware-service.ts
+++ b/src/store/shared-with-me-panel/shared-with-me-middleware-service.ts
@@ -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
});
diff --git a/src/store/side-panel/side-panel-action.ts b/src/store/side-panel/side-panel-action.ts
index fd08ee13..6d3e4746 100644
--- a/src/store/side-panel/side-panel-action.ts
+++ b/src/store/side-panel/side-panel-action.ts
@@ -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
});
diff --git a/src/store/trash/trash-actions.ts b/src/store/trash/trash-actions.ts
index 92d01582..693a0ece 100644
--- a/src/store/trash/trash-actions.ts
+++ b/src/store/trash/trash-actions.ts
@@ -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({
diff --git a/src/store/virtual-machines/virtual-machines-actions.ts b/src/store/virtual-machines/virtual-machines-actions.ts
index 1e9825c1..62564959 100644
--- a/src/store/virtual-machines/virtual-machines-actions.ts
+++ b/src/store/virtual-machines/virtual-machines-actions.ts
@@ -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());
diff --git a/src/store/workbench/workbench-actions.ts b/src/store/workbench/workbench-actions.ts
index 46ab1f59..46598bde 100644
--- a/src/store/workbench/workbench-actions.ts
+++ b/src/store/workbench/workbench-actions.ts
@@ -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[]) =>
diff --git a/src/views-components/context-menu/action-sets/collection-action-set.ts b/src/views-components/context-menu/action-sets/collection-action-set.ts
index 9d26fad2..d6095d10 100644
--- a/src/views-components/context-menu/action-sets/collection-action-set.ts
+++ b/src/views-components/context-menu/action-sets/collection-action-set.ts
@@ -41,12 +41,6 @@ export const collectionActionSet: ContextMenuActionSet = [[
}
},
{
- component: ToggleTrashAction,
- execute: (dispatch, resource) => {
- dispatch<any>(toggleCollectionTrashed(resource.uuid, resource.isTrashed!!));
- }
- },
- {
icon: MoveToIcon,
name: "Move to",
execute: (dispatch, resource) => dispatch<any>(openMoveCollectionDialog(resource))
@@ -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",
diff --git a/src/views-components/context-menu/action-sets/collection-resource-action-set.ts b/src/views-components/context-menu/action-sets/collection-resource-action-set.ts
index 7730b145..4b1d8fd8 100644
--- a/src/views-components/context-menu/action-sets/collection-resource-action-set.ts
+++ b/src/views-components/context-menu/action-sets/collection-resource-action-set.ts
@@ -41,12 +41,6 @@ export const collectionResourceActionSet: ContextMenuActionSet = [[
}
},
{
- component: ToggleTrashAction,
- execute: (dispatch, resource) => {
- dispatch<any>(toggleCollectionTrashed(resource.uuid, resource.isTrashed!!));
- }
- },
- {
icon: MoveToIcon,
name: "Move to",
execute: (dispatch, resource) => {
@@ -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",
diff --git a/src/views-components/context-menu/action-sets/project-action-set.ts b/src/views-components/context-menu/action-sets/project-action-set.ts
index 8c81e3bd..660d7ea0 100644
--- a/src/views-components/context-menu/action-sets/project-action-set.ts
+++ b/src/views-components/context-menu/action-sets/project-action-set.ts
@@ -48,12 +48,6 @@ export const projectActionSet: ContextMenuActionSet = [[
}
},
{
- component: ToggleTrashAction,
- execute: (dispatch, resource) => {
- dispatch<any>(toggleProjectTrashed(resource.uuid, resource.ownerUuid, resource.isTrashed!!));
- }
- },
- {
icon: MoveToIcon,
name: "Move to",
execute: (dispatch, resource) => {
@@ -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!!));
+ }
+ },
]];
diff --git a/src/views-components/data-explorer/renderers.tsx b/src/views-components/data-explorer/renderers.tsx
index ce4d430f..bb3f4e10 100644
--- a/src/views-components/data-explorer/renderers.tsx
+++ b/src/views-components/data-explorer/renderers.tsx
@@ -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>
diff --git a/src/views/collection-panel/collection-panel.tsx b/src/views/collection-panel/collection-panel.tsx
index 41a685f3..4124344d 100644
--- a/src/views/collection-panel/collection-panel.tsx
+++ b/src/views/collection-panel/collection-panel.tsx
@@ -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
}));
}
}
-----------------------------------------------------------------------
hooks/post-receive
--
More information about the arvados-commits
mailing list