Skip to content

Commit

Permalink
change mobile to touch event
Browse files Browse the repository at this point in the history
  • Loading branch information
felipe-ds-lima committed Feb 8, 2024
1 parent 35104f7 commit 8e32311
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 6 deletions.
2 changes: 1 addition & 1 deletion main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ export default class CopyImagePlugin extends Plugin {
);
} else {
// Mobile
this.registerDomEvent(document, "click", (evt: MouseEvent) => {
this.registerDomEvent(document, "touchstart", (evt: TouchEvent) => {
const images = document.getElementsByTagName("img");
(async () => {
for (let i = 0; i < images.length; i++) {
Expand Down
2 changes: 1 addition & 1 deletion manifest.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"id": "copy-image",
"name": "Copy Image",
"version": "1.0.5",
"version": "1.0.6",
"minAppVersion": "0.15.0",
"description": "Easily copy image from Obsidian to clipboard by right clicking image.",
"author": "Felipe D.S. Lima",
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "copy-image",
"displayName": "Copy Image",
"version": "1.0.5",
"version": "1.0.6",
"description": "Easily copy image from Obsidian to clipboard by right clicking image.",
"main": "main.js",
"scripts": {
Expand Down
3 changes: 2 additions & 1 deletion versions.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
{
"1.0.3": "0.15.0",
"1.0.4": "0.15.0",
"1.0.5": "0.15.0"
"1.0.5": "0.15.0",
"1.0.6": "0.15.0"
}

0 comments on commit 8e32311

Please sign in to comment.