💄 frontend: remove "Move" and "Download" options from trash (#662)
This commit is contained in:
@@ -203,7 +203,7 @@ export const useOnBuildContextMenu = (children: DriveItem[], initialParentId?: s
|
|||||||
{
|
{
|
||||||
type: 'menu',
|
type: 'menu',
|
||||||
text: Languages.t('components.item_context_menu.move_multiple'),
|
text: Languages.t('components.item_context_menu.move_multiple'),
|
||||||
hide: parent.access === 'read',
|
hide: parent.access === 'read' || inTrash,
|
||||||
onClick: () =>
|
onClick: () =>
|
||||||
setSelectorModalState({
|
setSelectorModalState({
|
||||||
open: true,
|
open: true,
|
||||||
@@ -227,6 +227,7 @@ export const useOnBuildContextMenu = (children: DriveItem[], initialParentId?: s
|
|||||||
{
|
{
|
||||||
type: 'menu',
|
type: 'menu',
|
||||||
text: Languages.t('components.item_context_menu.download_multiple'),
|
text: Languages.t('components.item_context_menu.download_multiple'),
|
||||||
|
hide: inTrash,
|
||||||
onClick: () =>
|
onClick: () =>
|
||||||
selectedCount === 1 ? download(checked[0].id) : downloadZip(checked.map(c => c.id)),
|
selectedCount === 1 ? download(checked[0].id) : downloadZip(checked.map(c => c.id)),
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in New Issue
Block a user