mirror of
https://github.com/Vendicated/Vencord.git
synced 2025-01-27 17:56:23 +00:00
ImageZoom: Fix incorrectly adding context menu in some places (#3150)
This commit is contained in:
parent
4036fbab92
commit
aac5242dc8
1 changed files with 6 additions and 1 deletions
|
@ -81,7 +81,12 @@ export const settings = definePluginSettings({
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
const imageContextMenuPatch: NavContextMenuPatchCallback = children => {
|
const imageContextMenuPatch: NavContextMenuPatchCallback = (children, props) => {
|
||||||
|
// Discord re-uses the image context menu for links to for the copy and open buttons
|
||||||
|
if ("href" in props) return;
|
||||||
|
// emojis in user statuses
|
||||||
|
if (props.target?.classList?.contains("emoji")) return;
|
||||||
|
|
||||||
const { square, nearestNeighbour } = settings.use(["square", "nearestNeighbour"]);
|
const { square, nearestNeighbour } = settings.use(["square", "nearestNeighbour"]);
|
||||||
|
|
||||||
children.push(
|
children.push(
|
||||||
|
|
Loading…
Reference in a new issue