Accept dropped files in the terminal (#1173)
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import { contextBridge, ipcRenderer } from "electron";
|
||||
import { contextBridge, ipcRenderer, webUtils } from "electron";
|
||||
|
||||
type EventHandler = (payload: unknown) => void;
|
||||
|
||||
@@ -55,6 +55,9 @@ contextBridge.exposeInMainWorld("paseoDesktop", {
|
||||
opener: {
|
||||
openUrl: (url: string) => ipcRenderer.invoke("paseo:opener:openUrl", url),
|
||||
},
|
||||
webUtils: {
|
||||
getPathForFile: (file: File) => webUtils.getPathForFile(file),
|
||||
},
|
||||
menu: {
|
||||
showContextMenu: (input?: Record<string, unknown>) =>
|
||||
ipcRenderer.invoke("paseo:menu:showContextMenu", input),
|
||||
|
||||
Reference in New Issue
Block a user