Skip to content

Commit

Permalink
Remove card options menu in grid layout (#365)
Browse files Browse the repository at this point in the history
  • Loading branch information
luorlandini authored Jul 28, 2021
1 parent ba38d11 commit b49bf02
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -84,9 +84,9 @@ const Cards = withResizeDetector(({
style={cardLayoutStyle === 'list' ? {} : containerStyle}
>
{resources.map((resource, idx) => {

const allowedOptions = options
.filter((opt) => hasPermissionsTo(resource?.perms, opt?.perms, 'resource'));
// enable allowedOptions (menu cards) only for list layout
const allowedOptions = (cardLayoutStyle === 'list') ? options
.filter((opt) => hasPermissionsTo(resource?.perms, opt?.perms, 'resource')) : [];

return (
<li
Expand Down

0 comments on commit b49bf02

Please sign in to comment.