aboutsummaryrefslogtreecommitdiffstats
path: root/src/webview/contextMenuBuilder.js
diff options
context:
space:
mode:
authorLibravatar Markus Hatvan <markus_hatvan@aon.at>2021-07-30 10:54:54 +0200
committerLibravatar GitHub <noreply@github.com>2021-07-30 14:24:54 +0530
commitf4b4416ea52d564bc2dbe543a82084ed98843ccc (patch)
tree7ca6b23571c86458a6b799746c91a7191de02715 /src/webview/contextMenuBuilder.js
parent5.6.1-nightly.8 [skip ci] (diff)
downloadferdium-app-f4b4416ea52d564bc2dbe543a82084ed98843ccc.tar.gz
ferdium-app-f4b4416ea52d564bc2dbe543a82084ed98843ccc.tar.zst
ferdium-app-f4b4416ea52d564bc2dbe543a82084ed98843ccc.zip
chore: migrate from tslint to @typescript-eslint (#1706)
- update .eslintrc to work for .js and .ts - update devDependencies - lint properly both root /src and nested /packages - update webhint recommended setting for tsconfig.json to shrink output - Manage all eslint rules from the repo root - escape single quotes in scripts to please windows build Co-authored-by: Vijay A <avijayr@protonmail.com>
Diffstat (limited to 'src/webview/contextMenuBuilder.js')
-rw-r--r--src/webview/contextMenuBuilder.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/webview/contextMenuBuilder.js b/src/webview/contextMenuBuilder.js
index 63eed2ebe..2598dbf03 100644
--- a/src/webview/contextMenuBuilder.js
+++ b/src/webview/contextMenuBuilder.js
@@ -61,7 +61,7 @@ module.exports = class ContextMenuBuilder {
61 * @param {function} processMenu If passed, this method will be passed the menu to change 61 * @param {function} processMenu If passed, this method will be passed the menu to change
62 * it prior to display. Signature: (menu, info) => menu 62 * it prior to display. Signature: (menu, info) => menu
63 */ 63 */
64 constructor(webContents, debugMode = false, processMenu = m => m) { 64 constructor(webContents, debugMode = false, processMenu = (m) => m) {
65 this.debugMode = debugMode; 65 this.debugMode = debugMode;
66 this.processMenu = processMenu; 66 this.processMenu = processMenu;
67 this.menu = null; 67 this.menu = null;
@@ -320,7 +320,7 @@ module.exports = class ContextMenuBuilder {
320 label: this.stringTable.copyImage(), 320 label: this.stringTable.copyImage(),
321 click: () => { 321 click: () => {
322 const result = this.convertImageToBase64(menuInfo.srcURL, 322 const result = this.convertImageToBase64(menuInfo.srcURL,
323 dataURL => clipboard.writeImage(nativeImage.createFromDataURL(dataURL))); 323 (dataURL) => clipboard.writeImage(nativeImage.createFromDataURL(dataURL)));
324 324
325 this._sendNotificationOnClipboardEvent(menuInfo.clipboardNotifications, () => `Image copied from URL: ${menuInfo.srcURL}`); 325 this._sendNotificationOnClipboardEvent(menuInfo.clipboardNotifications, () => `Image copied from URL: ${menuInfo.srcURL}`);
326 return result; 326 return result;