reflex icon indicating copy to clipboard operation
reflex copied to clipboard

[REF-3343] Can't paste in more than 1 file at the same time

Open dentroai opened this issue 1 year ago • 3 comments

Describe the bug Not sure if I'm doing something wrong, but it seems to me as if I'm only able to paste in a single file. When I select multiple files on my laptop, copy them and then paste them into the reflex app, only the first file is pasted.

When inspecting my event handler in debug mode, it seems like data is always an array of length 1, even though I pasted e.g. 3 files

async def on_paste(self, data):
        for type, content in data:

Is this something you are aware of?

To Reproduce Try to paste in multiple files

Expected behavior Expected behavior would be that I can paste in as many files as I want.

Specifics (please complete the following information):

  • Python Version: 3.12
  • Reflex Version: 0.5.7
  • OS: linux
  • Browser (Optional): firefox, chrome

Additional context paste event handler of this PR https://github.com/reflex-dev/reflex/pull/3513

REF-3343

dentroai avatar Jul 18 '24 14:07 dentroai

Can I work on this issue

vijayabhaskar78 avatar Oct 14 '24 13:10 vijayabhaskar78

@vijayabhaskar78 just assigned you!

picklelo avatar Oct 14 '24 18:10 picklelo

I'm working on issue REF-3343 and am still getting familiar with the codebase. I noticed references to "paste" in files like clipboard.py, dataeditor.py, and paste.js, but I'm unsure how to proceed with handling multiple file pastes. Could you guide me on the best approach or direct me to relevant parts of the code? Any tips would be really helpful as I’m new to contributing.

vijayabhaskar78 avatar Oct 15 '24 17:10 vijayabhaskar78