/HeroDatePicker

A Jetpack Compose Date Picker for Persian (Jalali) Calendar by Jetpack Compose.

Primary LanguageKotlinMIT LicenseMIT

HeroDatePicker

HeroDatePicker is a customizable date picker component for Android Jetpack Compose that allows users to easily select Persian (Jalali) dates in a visually appealing way. It features a sleek and modern design, with smooth animations and intuitive controls.

Banner

Download

Features:

  • Support for Persian (Jalali) calendar system
  • Customizable date format and locale
  • Ability to disable specific dates or date ranges
  • Integration with ViewModel for state management
  • Easy-to-use API with clear documentation

Setup

Configure the repositories

HeroDatePicker is available through the JitPack repository. You can declare this repository in your build script as follows:

Kotlin DSL
repositories {
    maven { url = uri("https://jitpack.io") }
}
Groovy DSL
repositories {
    maven { url 'https://jitpack.io' }
}

Add the dependency

After repository configuration, add a dependency on HeroDatePicker to your module's build.gradle file:

Kotlin DSL
dependencies {
    implementation("com.github.hamid97m:herodatepicker:1.0.0")
}
Groovy DSL
dependencies {
    implementation 'com.github.hamid97m:herodatepicker:1.0.0'
}

Usage

HeroDatePicker(Modifier.fillMaxWidth()) { selectedDate ->
    val (year, month, day) = selectedDate
    println("Selected Date: $year/$month/$day")
}

In addition, there is a sample app available in the project's sample directory that demonstrates how to use the library.

Screenshot

Contributing

We welcome contributions from the community! If you find a bug or have a feature request, please open an issue on the GitHub repository. If you'd like to contribute code, please fork the repository and submit a pull request.

License

HeroDatePicker is licensed under the MIT License.