fix: hide Open Original when sourceUrl is present to avoid redundancy
This commit is contained in:
@@ -73,6 +73,7 @@ export function buildMessageMenuItems(params: MessageMenuParams): ContextMenuIte
|
|||||||
copyImageToClipboard(imageUrl);
|
copyImageToClipboard(imageUrl);
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
if (!sourceUrl) {
|
||||||
items.push({
|
items.push({
|
||||||
key: 'open-original',
|
key: 'open-original',
|
||||||
type: 'action',
|
type: 'action',
|
||||||
@@ -86,6 +87,7 @@ export function buildMessageMenuItems(params: MessageMenuParams): ContextMenuIte
|
|||||||
window.open(imageUrl, '_blank', 'noopener');
|
window.open(imageUrl, '_blank', 'noopener');
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
}
|
||||||
items.push({ key: 'image-sep', type: 'separator' });
|
items.push({ key: 'image-sep', type: 'separator' });
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user