diff options
Diffstat (limited to 'src/plugins/betterUploadButton.ts')
-rw-r--r-- | src/plugins/betterUploadButton.ts | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/src/plugins/betterUploadButton.ts b/src/plugins/betterUploadButton.ts new file mode 100644 index 0000000..f2d2512 --- /dev/null +++ b/src/plugins/betterUploadButton.ts @@ -0,0 +1,18 @@ +import definePlugin from "../utils/types"; +import { Devs } from "../utils/constants"; + +export default definePlugin({ + name: "BetterUploadButton", + authors: [Devs.obscurity], + description: "Upload with a single click, open menu with right click", + patches: [ + { + find: "Messages.CHAT_ATTACH_UPLOAD_OR_INVITE", + replacement: { + match: /CHAT_ATTACH_UPLOAD_OR_INVITE,onDoubleClick:([^,]+),onClick:([^,]+)}}/, + replace: + "CHAT_ATTACH_UPLOAD_OR_INVITE,onClick:$1,onContextMenu:$2}}", + }, + }, + ], +}); |