Beta
Search
CTRLK

Selection

The Filenest.Selection is used to select multiple files to enable bulk actions.

  • Select files one by one using CTRL/CMD + LMB
  • Select multiple files at once using Shift + LMB
In your FileList you must spread a files rootProps onto a child for a file to be selectable and for this component to render.
The component must be used as a child of <Filenest.Root>

Example Usage

<Filenest.Selection
  children={({ count, bulkDelete }) => (
    <div>
      <div>{count} files selected:</div>
      <button onClick={bulkDelete}>
        Delete
      </button>
    </div>
  )}
/>

Render Props

PropTypeDefault
count
number
-
bulkDelete
() => void
-

On this page