Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[feat] File drag and drop problem, why can't it be the same as Electron? #7551

Closed
fanchenio opened this issue Aug 4, 2023 · 3 comments
Closed

Comments

@fanchenio
Copy link

Describe the problem

Electron can obtain the path of the dragged file by listening to the drop event in the HTML page, and can manipulate the DOM element during this period, which is very important to me, because when the user drags the file to the window, I need to give a prompt, What element is the dragged file above, and then modify the style, but Tauri can’t, tauri://file-drop can’t operate HTML at all, and can’t get the coordinates, and the original drop event can’t get the full path of the file, please Are there plans to address this issue in the future?

Describe the solution you'd like

The Drop event can get the file path.

Alternatives considered

No response

Additional context

No response

@fanchenio
Copy link
Author

1

Like this, you can manipulate HTML element styles while dragging and dropping files.

@ashutosh887
Copy link

@fanchenio Let me work on this issue

@FabianLars
Copy link
Member

Are there plans to address this issue in the future?

We're mainly waiting for Microsoft here actually: tauri-apps/wry#904.

But at least adding the coordinates for tauri's own drag drop api is possible and the groundwork is already done, we just need to expose it.

Also, going to close this as a duplicate of #3063

@FabianLars FabianLars closed this as not planned Won't fix, can't repro, duplicate, stale Aug 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants