QuantityPickerView

Additional

Language
Kotlin
Version
v1.0.2 (Jan 22, 2020)
Created
Jan 17, 2020
Updated
Mar 20, 2020
Owner
GuilhE
Contributors
GuilhE
GuilhE@Bliss (gdelgadobliss)
2
Activity
Badge
Generate
Download
Source code

Commercial

QuantityPickerView

A View capable of increasing or decreasing a unit value with a toggle animation.

Version 1.x

  • March, 2020 - View size will be equal to its state, in other words, expanded.size != colapsed.size:

  • January, 2020 - QuantityPickerView ????

Getting started

Include it into your project, for example, as a Gradle dependency:

implementation 'com.github.guilhe:quantity-picker-view:${LATEST_VERSION}'

Usage

Check out the sample module where you can find a few examples of how to create it by xml.

Attributes accepted in xml:

<resources>
    <attr name="min" format="integer" />
    <attr name="max" format="integer" />
    <attr name="value" format="integer" />
    <attr name="textLabelSize" format="dimension" />
    <attr name="textLabelFormatter" format="string" />
    <attr name="textLabelFont" format="reference" />
    <attr name="backgroundColor" format="color" />
    <attr name="btnRemove" format="reference" />
    <attr name="btnAdd" format="reference" />
    <attr name="isOpen" format="boolean" />
    <attr name="autoToggle" format="boolean" />
    <attr name="rippleEnable" format="boolean" />
    <attr name="rippleColor" format="color" />
</resources>

Example:

com.github.guilhe.views.QuantityPickerView
    android:layout_width="match_parent"
    android:layout_height="wrap_content"
    app:textLabelFont="@font/permanentmarker_regular"
    app:textLabelFormatter="%s units."
    app:textLabelSize="14sp"/>

Binaries

Binaries and dependency information for Gradle, Maven, Ivy and others can be found here.

Dependencies

Bugs and Feedback

For bugs, questions and discussions please use the Github Issues.

LICENSE

Copyright (c) 2020-present, GuilhE.

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.