Alwan 🎨 is an Android Jetpack Compose color picker library.

Overview

Alwan

Alwan is an Android Jetpack Compose color picker library.

Preview

Recording.mp4

image

Download

Gradle:

dependencies {
  implementation 'com.raedapps:alwan:1.0.1'
}

Usage Guide

You can use Alwan composable as following:

Alwan(
  onColorChanged = { color -> },
  modifier = Modifier.width(300.dp),
)

onColorChanged is called whenever the user selects a new color.

Providing the default color:

Use AlwanState to control the initially selected color:

Alwan(
  onColorChanged = { },
  modifier = Modifier.width(300.dp),
  state = rememberAlwanState(initialColor = Color.Yellow),
)

Showing the alpha slider

The alpha slider is hidden by default. Use the showAlphaSlider parameter to show it:

Alwan(
  onColorChanged = { },
  showAlphaSlider = true,
)

Using AlwanDialog

You can use the AlwanDialog as following:

AlwanDialog(
  onColorChanged = { },
  onDismissRequest = { },
)

AlwanDialog can be customized with positive & negative buttons:

AlwanDialog(
  onDismissRequest = { },
  onColorChanged = { },
  positiveButtonText = "OK",
  onPositiveButtonClick = { },
  negativeButtonText = "CANCEL",
  onNegativeButtonClick = { },
)

License

Copyright 2022 Raed Mughaus

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

   http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
You might also like...
Android time range picker

TimeRangePicker TimeRangePicker is a library which can be used to select a time range. WARNING Requires android-support-v4 Description This library pr

A date time range picker for android written in Kotlin
A date time range picker for android written in Kotlin

DateTimeRangePicker A date time range picker for android Usage Firstly, grab latest release of the library via JitPack. And note that, it utilizes Jod

A material Date Range Picker based on wdullaers MaterialDateTimePicker
A material Date Range Picker based on wdullaers MaterialDateTimePicker

Material Date and Time Picker with Range Selection Credits to the original amazing material date picker library by wdullaer - https://github.com/wdull

A material Date Range Picker based on wdullaers MaterialDateTimePicker
A material Date Range Picker based on wdullaers MaterialDateTimePicker

Material Date and Time Picker with Range Selection Credits to the original amazing material date picker library by wdullaer - https://github.com/wdull

Simplge ImageGallery Picker
Simplge ImageGallery Picker

SimpleImagePicker add camera and files permissions to manifest file uses-permission android:name="android.permission.CAMERA" / uses-permiss

Time-DatePicker - A Simple Time Date Picker With Kotlin

Time-DatePicker Time.DatePicker.mp4

JetCalendarView - A calendar library for Jetpack Compose
JetCalendarView - A calendar library for Jetpack Compose

JetCalendar WIP 2022 Hit Refresh! Calendar view ❤️ Jetpack Compose License Copyr

Kalendar - A calendar to integrate Calendar with Custom design in your jetpack compose project
Kalendar - A calendar to integrate Calendar with Custom design in your jetpack compose project

Kalendar - An Elementary Compose Calendar. This is a calendar to integrate Calen

Material3 themed Jetpack Compose date & time pickers.
Material3 themed Jetpack Compose date & time pickers.

Compose material3 Date1 and Time pickers Highly customizable Jetpack Compose components with material3 support for date & time picking. Contents Lates

Owner
Raed Mughaus
Raed Mughaus
Appleader707 1 Aug 9, 2022
Nepali Date Picker library in Jetpack compose for android with Date conversion from BS to AD and vice-versa

Nepali Date picker Converter - Re in Compose This is a re-work of Nepali Date Picker Converter in jetpack compose and kotlin. English Locale Nepali Lo

Kiran Gyawali 4 Dec 23, 2022
JetCountrypicker - Country code bottomsheet picker in Jetpack Compose

JetCountryPicker Country code bottomsheet picker in Jetpack Compose How to add i

Canopas Software 30 Nov 17, 2022
Android Compose wheel picker library based on LazyColumn in vertical and LazyRow in horizontal.

About Android Compose wheel picker library based on LazyColumn in vertical and LazyRow in horizontal. Gradle Sample Default Item size Unfocused count

null 6 Dec 22, 2022
A simple compose weight picker drawn with canvas.

CanvasWeightPicker A simple compose weight picker drawn with canvas. Features Drag scale to select weight Haptic feedback on weight selected Video of

Timothy Serem 5 Dec 2, 2022
[NO LONGER MAINTAINED] Android library for better Picker DialogFragments

/!\ This Project is no longer maintained /!\ DialogFragments modeled after the AOSP Clock and Calendar apps to improve UX for picking time, date, numb

Code-Troopers 2.7k Dec 29, 2022
[NO LONGER MAINTAINED] Android library for better Picker DialogFragments

/!\ This Project is no longer maintained /!\ DialogFragments modeled after the AOSP Clock and Calendar apps to improve UX for picking time, date, numb

Code-Troopers 2.7k Dec 29, 2022
A customizable, easy-to-use, and functional circular time range picker library for Android

A customizable, easy-to-use, and functional circular time range picker library for Android. Use this library to mimic Apple's iOS or Samsung's bedtime picker.

Joery Droppers 251 Dec 30, 2022
Monet color system with Material You

Monet Google's Monet color system (Android 12 Beta 2) library. Usage Jetpack Compose Generate Monet color palette monetColorsOf(Color, darkTheme) Loca

null 5 Feb 16, 2022
Color-My-View-App - Layouts - ColorMyViews app

Layouts - ColorMyViews app This is the second toy app for lesson 2 of the Androi

null 0 Jan 7, 2022