Closed takebo closed 4 years ago
Yes, I'm here for the same reason. Looking at csvreader.tsx, the very narrow width (100px) of the filename box looks strange and I'd like to widen it and get rid of the gradient. I tried various things like the below, hoping I could modify the dropFile part of the internal 'styles' object, but no success so far. Any thoughts would be great!
const myStyle = {
dropFile: {
width: 400
}
}
return (
<CSVReader
style={myStyle}
onError={handleOnError}
onFileLoad={handleOnFileLoad}
config={papaConfig}
addRemoveButton
onRemoveFile={handleOnRemoveFile}
>
<span className="fileDrop">{props.promptText}</span>
</CSVReader>
)
At line 431 of csvreader.tsx we have this:
<div style={Object.assign({}, styles.dropFile, styles.column)}>
If we could just add props.style to the end of that, would we be in business?
@takebo @glinkot Well, I will check it and release it for the next version next week. Anyway could I add you in the contributors list?
@Bunlong Nice, thank you. Sure, i wouldn't mind.
Sure! Thanks :)
Sent from Outlook Mobilehttps://aka.ms/blhgte
From: Bruno notifications@github.com Sent: Thursday, July 16, 2020 10:21:21 PM To: Bunlong/react-papaparse react-papaparse@noreply.github.com Cc: glinkot foley.mark@gmail.com; Mention mention@noreply.github.com Subject: Re: [Bunlong/react-papaparse] Customize UI (#34)
@Bunlonghttps://github.com/Bunlong Nice, thank you. Sure, i wouldn't mind.
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://github.com/Bunlong/react-papaparse/issues/34#issuecomment-659374854, or unsubscribehttps://github.com/notifications/unsubscribe-auth/ADICH4YOJEPNIQIMNQJVRPLR33WEDANCNFSM4OXMKMSA.
Hi @Bunlong, any luck putting this small change in? I'd rather not bugger about forking it just to change that one line 👍.
My app looks great except for the big weird grey box in the middle...
Thanks for your help
@glinkot @takebo Please upgrade react-papaparse to latest version (3.5.0) and check the following wiki to customize CSVReader. You were added to contributors list. Thanks!
react-papaparse v3.5.0 has been released!
Minor version with the following changes:
Wiki:
Fantastic, thanks so much for that! I'll check this out tomorrow morning, looking forward to it.
On Tue, 28 Jul 2020 at 04:03, Bunlong VAN notifications@github.com wrote:
@glinkot https://github.com/glinkot @takebo https://github.com/takebo Please upgrade react-papaparse to latest version (3.5.0) and check the following wiki to customize CSVReader. You were added to contributors list. Thanks!
react-papaparse v3.5.0 has been released!
Minor version with the following changes:
- Enable to customize CSVReader (Drag Upload) dropFile style
Wiki:
- How to customize CSVReader (Drag Upload) dropFile style? https://github.com/Bunlong/react-papaparse/wiki/CSVReader-Drag-Upload-dropFile-Style
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/Bunlong/react-papaparse/issues/34#issuecomment-664550965, or unsubscribe https://github.com/notifications/unsubscribe-auth/ADICH44J3B5VMVD7IXOV7FDR5W6OVANCNFSM4OXMKMSA .
That is awesome @Bunlong ! Thanks alot!
@takebo @glinkot You are very welcome. Could we close the issue? Thanks!
Yes, for sure. Thanks again.
@glinkot You are very welcome. Thanks!
Is there a way to customize the styles of the components? Especially on the drag and drop, i want to customize the box that shows up with the filename, progress bar, etc