Browse Source
All tooltips to action icons in CfdTable
It makes it a bit easier to use, especially for newcomers
testing
Mariusz Klochowicz
3 years ago
No known key found for this signature in database
GPG Key ID: 470C865699C8D4D
1 changed files with
11 additions and
8 deletions
-
frontend/src/components/cfdtables/CfdTable.tsx
|
@ -22,6 +22,7 @@ import { |
|
|
Td, |
|
|
Td, |
|
|
Th, |
|
|
Th, |
|
|
Thead, |
|
|
Thead, |
|
|
|
|
|
Tooltip, |
|
|
Tr, |
|
|
Tr, |
|
|
useToast, |
|
|
useToast, |
|
|
VStack, |
|
|
VStack, |
|
@ -179,14 +180,16 @@ export function CfdTable( |
|
|
Header: "Action", |
|
|
Header: "Action", |
|
|
accessor: ({ actions, order_id }) => { |
|
|
accessor: ({ actions, order_id }) => { |
|
|
const actionIcons = actions.map((action) => { |
|
|
const actionIcons = actions.map((action) => { |
|
|
return (<IconButton |
|
|
return (<Tooltip label={action}> |
|
|
key={action} |
|
|
<IconButton |
|
|
colorScheme={colorSchemaForAction(action)} |
|
|
key={action} |
|
|
aria-label={action} |
|
|
colorScheme={colorSchemaForAction(action)} |
|
|
icon={iconForAction(action)} |
|
|
aria-label={action} |
|
|
onClick={() => postAction(order_id, action)} |
|
|
icon={iconForAction(action)} |
|
|
isLoading={isActioning} |
|
|
onClick={() => postAction(order_id, action)} |
|
|
/>); |
|
|
isLoading={isActioning} |
|
|
|
|
|
/> |
|
|
|
|
|
</Tooltip>); |
|
|
}); |
|
|
}); |
|
|
|
|
|
|
|
|
return <HStack>{actionIcons}</HStack>; |
|
|
return <HStack>{actionIcons}</HStack>; |
|
|