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

Disabling Filter at top page #160

Open
mikecrophones07 opened this issue Jan 18, 2021 · 3 comments
Open

Disabling Filter at top page #160

mikecrophones07 opened this issue Jan 18, 2021 · 3 comments

Comments

@mikecrophones07
Copy link

mikecrophones07 commented Jan 18, 2021

Hello, is their anyway to disble or visible=false for filter at the top of the page? Thanks for the feedback

@jlo-1
Copy link
Contributor

jlo-1 commented Jan 19, 2021

The browser specifies the filter through props and has a defaultProp set
See here: https://github.com/uptick/react-keyed-file-browser/blob/master/src/browser.js#L127

If you don't wish to have the default filter you should explicitly set the prop to a function that returns null. Furthermore, if you have no other actions, the actionRenderer will render with nothing taking up excess space which may not be desired.To avoid this you could also set ActionRenderer prop to return null.

i.e

<FileBrowser
  ...
  FilterRenderer={() => null}
  ActionRenderer={() => null}
  ...
/>

Hope this helps :)

@mikecrophones07
Copy link
Author

mikecrophones07 commented Jan 19, 2021

Hi @jlo-1

thanks, the filter section is gone.
another question, with regards to column headers, there are default columns: Name, Type, and Last Modified.
can I customize it by specifying my own columns and values per file and folder? I saw that there's a props headerRenderer and headerRendererProps but don't know how to implement it. Can you provide samples for it. Seems like I cant find resources in creating TableHeader

Thanks hoping for your reply :)

@raguiar2
Copy link

raguiar2 commented Dec 4, 2021

@mikecrophones07 use headerRenderer={() => null} as a prop to FileBrowser

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants