Skip to content

Commit

Permalink
Merge pull request #12 from DoodleScheduling/develop
Browse files Browse the repository at this point in the history
Develop
  • Loading branch information
AlexanderThiele committed Apr 8, 2016
2 parents fe1030d + 9837e82 commit 89cad33
Show file tree
Hide file tree
Showing 14 changed files with 226 additions and 98 deletions.
18 changes: 18 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
1.1.0
-----

##### Features

* Added attribute `app:cv_max_height="${dimension}"` to make the ChipView's content scrollable beyond this limit (fixes #8)
* Added attribute `app:cv_vertical_spacing="${dimension}"` to allow configurable spacing between rows (fixes #4)

##### Misc

* Added `getChips()` (fixes #6)
* Added `getEditText()`, e.g. to allow the ChipsView to be made non-editable (fixes #2)
* Improved the cursor's alignment to be centered towards the Chips in its row
* Improved the sample application

##### Upgrade Notes

As the ChipsView itself is now a ScrollView you may want to remove any ScrollView that you already used to wrap the ChipView's content and use `app:cv_max_height` instead.
12 changes: 10 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ buildscript {
}
dependencies {
compile 'com.doodle.android:android-material-chips:1.0.1'
compile 'com.doodle.android:android-material-chips:1.1.0'
}
```

Expand All @@ -46,7 +46,7 @@ repositories {
}
dependencies {
compile 'com.github.DoodleScheduling:android-material-chips:1.0.1'
compile 'com.github.DoodleScheduling:android-material-chips:1.1.0'
}
```

Expand All @@ -72,6 +72,8 @@ Include ```xmlns:app="http://schemas.android.com/apk/res-auto"``` and customize
android:id="@+id/chipsView"
android:layout_width="match_parent"
android:layout_height="wrap_content"
app:cv_max_height="120dp"
app:cv_vertical_spacing="2dp"
app:cv_bg_color="#f00"
app:cv_bg_color_clicked="#0f0"
app:cv_bg_color_error_clicked="#0f0"
Expand Down Expand Up @@ -124,6 +126,12 @@ mChipsView.setChipsListener(new ChipsView.ChipsListener() {
mChipsView.addChip(email, imgUrl, contact);
```

**Add a non-removable chip.**

```java
mChipsView.addChip(email, imgUrl, contact, true);
```

**Remove a chip**

```java
Expand Down
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ buildscript {
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:1.5.0'
classpath 'com.android.tools.build:gradle:2.0.0'
classpath 'com.github.dcendents:android-maven-gradle-plugin:1.3'
}
}
Expand Down
4 changes: 2 additions & 2 deletions gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#Wed Oct 21 11:34:03 PDT 2015
#Fri Apr 08 16:34:54 CEST 2016
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-2.8-all.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-2.10-all.zip
10 changes: 7 additions & 3 deletions library/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,11 @@ android {
defaultConfig {
minSdkVersion 16
targetSdkVersion 23
versionCode 2
versionName "1.0.1"
versionCode 3
versionName "1.1.0"
setProperty("archivesBaseName", "android-material-chips-$versionName")
}

buildTypes {
release {
minifyEnabled false
Expand All @@ -24,7 +25,9 @@ dependencies {
compile 'com.squareup.picasso:picasso:2.5.2'
compile 'com.android.support:appcompat-v7:23.1.1'
compile 'com.rengwuxian.materialedittext:library:2.1.4'
testCompile 'junit:junit:4.12'
}

task sourcesJar(type: Jar) {
from android.sourceSets.main.java.srcDirs
classifier = 'sources'
Expand All @@ -39,7 +42,8 @@ task javadocJar(type: Jar, dependsOn: javadoc) {
classifier = 'javadoc'
from javadoc.destinationDir
}

artifacts {
archives javadocJar
archives sourcesJar
}
}
Loading

0 comments on commit 89cad33

Please sign in to comment.