FileKit Dialogs
File picker dialog
Open a file picker dialog in a Kotlin Multiplatform project
Supported on Android, iOS, macOS, JVM, JS and WASM targets
Quick start
The file picker component provides a native interface for users to browse and select files from their device. It supports various file types and offers customization options to fit different use cases.
Selection mode
Select one or multiple files using the mode
parameter.
Single
- Allows the user to select a single file.Multiple()
- Allows the user to select multiple files.
Filter by type
Filter the files by their type using the type
parameter. You can pick different types of files with FileKitType
:
Image
: Pick an image file.Video
: Pick a video file.ImageAndVideo
: Pick an image or a video file.File()
: Pick any file. It is the default type. It’s possible to specify a list of extensions.
On Android and iOS, using Image, Video or ImageAndVideo FileKitType will open a gallery picker. Read more here.
Customizing the dialog
You can customize the dialog by setting the title, the initial directory and some settings relative to the platform.
Read more about dialog settings to customize the dialog for each platform.