19569: Add open in new tab action to process resource action set 19569-process-open-newtab
authorStephen Smith <stephen@curii.com>
Wed, 26 Oct 2022 13:56:24 +0000 (09:56 -0400)
committerStephen Smith <stephen@curii.com>
Wed, 26 Oct 2022 13:56:24 +0000 (09:56 -0400)
Arvados-DCO-1.1-Signed-off-by: Stephen Smith <stephen@curii.com>

src/views-components/context-menu/action-sets/process-resource-action-set.ts

index 56cfee85d1a4388fe261e1b1ffe2ba5b413ff902..78b2f340b8d814efbb9800ab396c3858964313a5 100644 (file)
@@ -8,7 +8,8 @@ import { toggleFavorite } from "store/favorites/favorites-actions";
 import {
     RenameIcon, ShareIcon, MoveToIcon, CopyIcon, DetailsIcon,
     RemoveIcon, ReRunProcessIcon, OutputIcon,
-    AdvancedIcon
+    AdvancedIcon,
+    OpenIcon
 } from "components/icon/icon";
 import { favoritePanelActions } from "store/favorite-panel/favorite-panel-action";
 import { openMoveProcessDialog } from 'store/processes/process-move-actions';
@@ -23,6 +24,7 @@ import { openAdvancedTabDialog } from "store/advanced-tab/advanced-tab";
 import { TogglePublicFavoriteAction } from "../actions/public-favorite-action";
 import { togglePublicFavorite } from "store/public-favorites/public-favorites-actions";
 import { publicFavoritePanelActions } from "store/public-favorites-panel/public-favorites-action";
+import { openInNewTabAction } from "store/open-in-new-tab/open-in-new-tab.actions";
 
 export const readOnlyProcessResourceActionSet: ContextMenuActionSet = [[
     {
@@ -33,6 +35,13 @@ export const readOnlyProcessResourceActionSet: ContextMenuActionSet = [[
             });
         }
     },
+    {
+        icon: OpenIcon,
+        name: "Open in new tab",
+        execute: (dispatch, resource) => {
+            dispatch<any>(openInNewTabAction(resource));
+        }
+    },
     {
         icon: CopyIcon,
         name: "Copy to project",