React-dropzone: on drag over show a div

Created on 7 Nov 2016  路  4Comments  路  Source: react-dropzone/react-dropzone

Hello,

Is what it would be possible at on drag over area we did appear a div (like a modal / dialog) instead of just changing the css a border ?

Thx for any help,

Best regards,

Example (Slack)
tetsersss

All 4 comments

There are different callback available: https://github.com/okonet/react-dropzone/blob/master/src/index.js#L316 so you can hook in and react to different user actions as you wish. So I believe yes, you can implement anything you want.

Thank you for your reply,
Can you give me any example pls ?
I've do :

onDragEnter(){
      return(
        <div className="dropZone">
          <div className="dropZoneContent">
            <h3>DRAG & DROP</h3>
            <p>import your file</p>
          </div>
        </div>
      );
    }

But I dont know how bind this function for to have a render with div

Sorry, I can't give you an example. You can hire me to implement this though.

Either way, you'll still need to handle global drag events on your own. See #149

It's ok, I've found my misstake -> i've forget .bind(this)
No thank you, I shouldn't pay for help while there are sites like StackOverflow or people to help debug.
Thank you for this wonderful plugin anyway!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

emilpriver picture emilpriver  路  3Comments

Mattensor picture Mattensor  路  3Comments

Mangatt picture Mangatt  路  4Comments

reemtariqq picture reemtariqq  路  4Comments

xswordsx picture xswordsx  路  3Comments