Skip to content

Commit

Permalink
Pump up version to 2.0.1
Browse files Browse the repository at this point in the history
  • Loading branch information
minibugdev committed Dec 29, 2020
1 parent 08e34f8 commit 2f3ae63
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 4 deletions.
6 changes: 4 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Drawable Badge
[![CircleCI](https://circleci.com/gh/minibugdev/DrawableBadge.svg?style=shield)](https://circleci.com/gh/minibugdev/DrawableBadge)
[![Release](https://jitpack.io/v/minibugdev/DrawableBadge.svg)](https://jitpack.io/#minibugdev/DrawableBadge/2.0.0)
[![Release](https://jitpack.io/v/minibugdev/DrawableBadge.svg)](https://jitpack.io/#minibugdev/DrawableBadge/2.0.1)
[![GitHub license](https://img.shields.io/badge/license-MIT-blue.svg)](https://raw.githubusercontent.com/minibugdev/DrawableBadge/master/LICENSE)

Drawable Badge is a android library for adding badges to drawables.
Expand All @@ -21,6 +21,7 @@ val drawable = DrawableBadge.Builder(context)
.badgeBorderColor(R.color.badgeBorderColor)
.badgeBorderSize(R.dimen.badge_border_size)
.maximumCounter(99)
.showCounter(true)
.build()
.get(99)
```
Expand All @@ -42,6 +43,7 @@ imageViewBadge.setImageDrawable(drawable)
- `badgeBorderColor`: Badge border color resource id , default `#FFFFFF`.
- `badgeBorderSize`: Badge border size supported `@DimenRes` or `@Px`, default `0.5dp`.
- `maximumCounter`: Maximum counter text will append with `+`, default and not more than `99`.
- `showCounter`: Set visible of badge counter number, default `true`.

#### Deprecated
- `badgePosition`: Position of Badge which need to added.
Expand All @@ -54,7 +56,7 @@ repositories {
```

``` groovy
compile 'com.github.minibugdev:drawablebadge:2.0.0'
compile 'com.github.minibugdev:drawablebadge:2.0.1'
```


Expand Down
4 changes: 2 additions & 2 deletions library/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ android {
defaultConfig {
minSdkVersion 14
targetSdkVersion 30
versionCode 5
versionName "2.0.0"
versionCode 6
versionName "2.0.1"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
buildTypes {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ class DrawableBadgeBuilderTest {
.badgeGravity(Gravity.CENTER_VERTICAL or Gravity.END)
.showBorder(false)
.maximumCounter(50)
.showCounter(false)
.build()

val expectedBadgeColor = ContextCompat.getColor(context, android.R.color.holo_red_dark)
Expand All @@ -83,5 +84,6 @@ class DrawableBadgeBuilderTest {
assertEquals(Gravity.CENTER_VERTICAL or Gravity.END, actual.badgeGravity)
assertEquals(false, actual.isShowBorder)
assertEquals(50, actual.maximumCounter)
assertEquals(false, actual.isShowCounter)
}
}

0 comments on commit 2f3ae63

Please sign in to comment.