reactjs - Add button Dropzone -
i have 2 components list , form. onthes components, i'm using dropzone disabled click, drag , drop possible but, on form component, add button, wich enable add dcument in browsing.
in form component, call component dropzone
<uploadzone onupload={this.props.oncreatedocument} onsuccessupload={this.uploadedfile} lastfileupload={this.props.lastuploadfile} />
i've added button :
<raisedbutton label="add" primary={true} onclick={this.browsedz}/> browsedz = () => { }
i don't know how call dropzone on button add document thank yours answers
you wouldn't use dropzone part, implement yourself. use trick put button in <label htmlfor={id}>
, have file input same id. you'll have 2 ways of receiving files, store latest selection user in 1 state key.
Comments
Post a Comment