Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

- update to SDK 2.0.8 #113

Merged
merged 1 commit into from
Jan 14, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 10 additions & 1 deletion Docs.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ maven {

Then add the GIPHY SDK dependency in the module ```build.gradle``` file:
```
implementation 'com.giphy.sdk:ui:2.0.7'
implementation 'com.giphy.sdk:ui:2.0.8'
```

### Basic Setup
Expand Down Expand Up @@ -152,6 +152,11 @@ settings.stickerColumnCount: Int = 3
settings.showSuggestionsBar = false
```

- **Image Format**: You can choose a file type for the grid.
```kotlin
settings.imageFormat = ImageFormat.WEBP
```

#### Presentation
Show your `GiphyDialogFragment` using the `SupportFragmentManager` and watch as the GIFs start flowin'.

Expand Down Expand Up @@ -273,6 +278,7 @@ If you require a more flexible experience, use the `GiphyGridView` instead of th
- **cellPadding** - spacing between rendered GIFs
- **showViewOnGiphy** - enables/disables the `Show on Giphy` action in the long-press menu
- **showCheckeredBackground** - use a checkered background (for stickers only)
- **imageFormat** - choose a file type for the grid
- **fixedSizeCells** - display content in equally sized cells (for stickers only)

## Loading GIFs using `GPHContent`
Expand Down Expand Up @@ -373,6 +379,9 @@ In order to interact with the `GiphyGridView` you can apply the following callba

```kotlin
interface GPHGridCallback {
/**
* @param resultCount results count, in case of error it equals -1
*/
fun contentDidUpdate(resultCount: Int)
fun didSelectMedia(media: Media)
}
Expand Down
2 changes: 1 addition & 1 deletion app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ dependencies {
implementation "androidx.appcompat:appcompat:1.1.0"
implementation "androidx.constraintlayout:constraintlayout:1.1.3"
implementation "com.google.android.material:material:1.1.0"
implementation "com.giphy.sdk:ui:2.0.7"
implementation "com.giphy.sdk:ui:2.0.8"
implementation "com.squareup.leakcanary:leakcanary-android:1.6.3"
implementation "com.github.savvyapps:ToggleButtonLayout:1.2.0"
implementation "androidx.gridlayout:gridlayout:1.0.0"
Expand Down