giphy_flutter_sdk 2.0.0
giphy_flutter_sdk: ^2.0.0 copied to clipboard
A Flutter plugin for integrating Giphy SDK in Android/iOS application.
2.0.0 #
Native SDKs #
Breaking Changes #
- iOS: apps now need iOS 15.0 or later and Xcode 26.4 or later (the first Xcode with the Swift 6.3 compiler), because GIPHY iOS SDK 2.4.0 requires them. Apps can still be written in Swift 5 language mode or Objective-C.
- iOS: with CocoaPods, set your Podfile's
platform :iosto 15.0 or later.
Bug Fixes #
- Android:
GiphyVideoView.onPlaybackStateChangednow reportsplaying,pausedandunknown. Android sent these states under a key the Dart side didn't read, so they all arrived asunknown. - Android:
GiphyVideoManager.pauseAll()now reportspausedto the video view that was playing. - Android: the bundled ExoPlayer video player adapter now sends
GPHVideoPlayerState.MuteChanged(true)when the player is muted, as the GIPHY Android SDK defines it, andGiphyVideoViewreports that asonMute. If you use a custom video player adapter copied from an earlier version, changeMuteChanged(volume > 0)toMuteChanged(muted = volume == 0f). OtherwiseonMuteandonUnmuteare swapped. - Passing a
GiphyMediathat lacks some renditions toGiphyMediaView(media:)orGiphyVideoView(media:)no longer throws "Unsupported rendition type". GiphyMediaViewandGiphyVideoViewignore the answer to a media lookup once they were given other media. Before, a slow lookup could replace newer media, or report an error for media the view no longer shows.GiphyVideoViewpauses when the app goes to the background and plays again when it comes back. Since Flutter 3.13 reports the steps in between (inactive,hidden), the plugin no longer noticed the change: on iOS a clip stopped in the background and didn't play again. A clip the user unmuted comes back muted and reportsonMute.- iOS:
GiphyVideoViewis released once Flutter disposes it, and a clip it was playing stops. Before, a registry kept every video view alive, and the shared player kept playing into a removed view. - Android: a disposed
GiphyVideoViewno longer gets media loaded into it by a late lookup or byGiphyVideoManager.resume().
Developer Tooling #
- Replace the template tests with Dart unit tests (
flutter test) and integration tests that run the example app against the native SDKs (cd example && flutter test integration_test -d <device-id>). See CONTRIBUTING.md. - The example app now needs Flutter 3.47.0 or newer. Apps using the plugin aren't affected.
1.1.0 #
Build System #
- Migrate Android Gradle setup toward AGP 9 built-in Kotlin support.
- The plugin now uses AGP built-in Kotlin on AGP 9+ when built-in Kotlin is enabled.
- The plugin still falls back to the Kotlin Gradle Plugin for AGP < 9.
- For compatibility, AGP 9+ consumers that explicitly set
android.builtInKotlin=falsealso use the Kotlin Gradle Plugin fallback. Those builds may still show AGP's KGP deprecation warning for:giphy_flutter_sdk. - AGP 9+ consumers can keep
android.newDsl=falsefor Flutter's temporary legacy DSL compatibility, but should leave built-in Kotlin enabled to avoid the SDK KGP warning. - Android Java/Kotlin compilation now targets JVM 17.
- The Android plugin default
GiphyFlutterSDK.compileSdkVersionis now 34. - Update the Android example project Gradle setup for AGP 9 and Flutter 3.44 compatibility.
- Add iOS Swift Package Manager support for the plugin while keeping CocoaPods support for existing consumers.
- Migrate the iOS example app from CocoaPods to Flutter Swift Package Manager integration.
Developer Tooling #
- Add
scripts/sdk.sh cleanto remove generated Flutter, Gradle, CocoaPods, SwiftPM, and iOS build artifacts from the SDK package and example app. - Update
scripts/sdk.sh bump iosto keep the iOSPackage.swiftdependency version in sync with the podspec. - Add
scripts/sdk.sh bump [patch|minor|major|x.y.z]to update the Flutter package version inpubspec.yaml. - Add
scripts/sdk.sh publish-dry-runandscripts/sdk.sh publishhelpers for pub.dev publishing.