X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/0f55c7182b5231712e77f2538dd0c69336558647..72a8bf2138429b61dfc9710cc41932396b6f5b4f:/src/views-components/context-menu/action-sets/ssh-key-action-set.ts?ds=sidebyside diff --git a/src/views-components/context-menu/action-sets/ssh-key-action-set.ts b/src/views-components/context-menu/action-sets/ssh-key-action-set.ts index d1a94cd311..f0620ede0a 100644 --- a/src/views-components/context-menu/action-sets/ssh-key-action-set.ts +++ b/src/views-components/context-menu/action-sets/ssh-key-action-set.ts @@ -2,27 +2,33 @@ // // SPDX-License-Identifier: AGPL-3.0 -import { ContextMenuActionSet } from "views-components/context-menu/context-menu-action-set"; -import { AdvancedIcon, RemoveIcon, AttributesIcon } from "components/icon/icon"; +import { ContextMenuActionSet } from 'views-components/context-menu/context-menu-action-set'; +import { AdvancedIcon, RemoveIcon, AttributesIcon } from 'components/icon/icon'; import { openSshKeyRemoveDialog, openSshKeyAttributesDialog } from 'store/auth/auth-action-ssh'; import { openAdvancedTabDialog } from 'store/advanced-tab/advanced-tab'; -export const sshKeyActionSet: ContextMenuActionSet = [[{ - name: "Attributes", - icon: AttributesIcon, - execute: (dispatch, { uuid }) => { - dispatch(openSshKeyAttributesDialog(uuid)); - } -}, { - name: "API Details", - icon: AdvancedIcon, - execute: (dispatch, { uuid }) => { - dispatch(openAdvancedTabDialog(uuid)); - } -}, { - name: "Remove", - icon: RemoveIcon, - execute: (dispatch, { uuid }) => { - dispatch(openSshKeyRemoveDialog(uuid)); - } -}]]; +export const sshKeyActionSet: ContextMenuActionSet = [ + [ + { + name: 'Attributes', + icon: AttributesIcon, + execute: (dispatch, resources) => { + resources.forEach((resource) => dispatch(openSshKeyAttributesDialog(resource.uuid))); + }, + }, + { + name: 'API Details', + icon: AdvancedIcon, + execute: (dispatch, resources) => { + resources.forEach((resource) => dispatch(openAdvancedTabDialog(resource.uuid))); + }, + }, + { + name: 'Remove', + icon: RemoveIcon, + execute: (dispatch, resources) => { + resources.forEach((resource) => dispatch(openSshKeyRemoveDialog(resource.uuid))); + }, + }, + ], +];