From fda1f384119216514bd749fedd0dc669989e2411 Mon Sep 17 00:00:00 2001 From: denisr Date: Wed, 18 Oct 2023 08:52:56 +0200 Subject: [PATCH] Updated Android and iOS SDK --- CHANGELOG.md | 6 +++++- android/build.gradle | 4 ++-- example/android/build.gradle | 2 +- ios/Classes/KlaviyoFlutterPlugin.swift | 6 +++--- ios/klaviyo_flutter.podspec | 2 +- pubspec.yaml | 4 ++-- 6 files changed, 14 insertions(+), 10 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index f8321b6..d260ce1 100755 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,12 +1,16 @@ # Changelog +## 0.0.3+1 + +* Updated Android SDK to 1.3.4, Updated iOS SDK to 2.2.1 + ## 0.0.2+3 * Fix for option properties in Android, Updated Android SDK to 1.1.1 ## 0.0.2+2 -* Fix for sending properties to Klaviyo API via Android +* Fix for sending properties to Klaviyo API via Android ## 0.0.2+1 diff --git a/android/build.gradle b/android/build.gradle index 9affcb9..70d74e0 100644 --- a/android/build.gradle +++ b/android/build.gradle @@ -42,7 +42,7 @@ android { dependencies { implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlin_version" - implementation "com.github.klaviyo.klaviyo-android-sdk:analytics:1.1.1" - implementation "com.github.klaviyo.klaviyo-android-sdk:push-fcm:1.1.1" + implementation "com.github.klaviyo.klaviyo-android-sdk:analytics:1.3.4" + implementation "com.github.klaviyo.klaviyo-android-sdk:push-fcm:1.3.4" implementation 'com.google.firebase:firebase-messaging-ktx:23.1.2' } diff --git a/example/android/build.gradle b/example/android/build.gradle index c140541..790a10e 100644 --- a/example/android/build.gradle +++ b/example/android/build.gradle @@ -26,6 +26,6 @@ subprojects { project.evaluationDependsOn(':app') } -task clean(type: Delete) { +tasks.register("clean", Delete) { delete rootProject.buildDir } diff --git a/ios/Classes/KlaviyoFlutterPlugin.swift b/ios/Classes/KlaviyoFlutterPlugin.swift index c7d7999..ff7149e 100644 --- a/ios/Classes/KlaviyoFlutterPlugin.swift +++ b/ios/Classes/KlaviyoFlutterPlugin.swift @@ -46,11 +46,11 @@ public class KlaviyoFlutterPlugin: NSObject, FlutterPlugin, UNUserNotificationCe public func userNotificationCenter(_ center: UNUserNotificationCenter, willPresent notification: UNNotification, withCompletionHandler completionHandler: @escaping (UNNotificationPresentationOptions) -> Void) { + var options: UNNotificationPresentationOptions = [.alert] if #available(iOS 14.0, *) { - completionHandler([.list, .banner]) - } else { - completionHandler([.alert]) + options = [.list, .banner] } + completionHandler(options) } public func handle(_ call: FlutterMethodCall, result: @escaping FlutterResult) { diff --git a/ios/klaviyo_flutter.podspec b/ios/klaviyo_flutter.podspec index e37898d..8cb3ae2 100644 --- a/ios/klaviyo_flutter.podspec +++ b/ios/klaviyo_flutter.podspec @@ -14,7 +14,7 @@ A new flutter plugin project. s.source = { :path => '.' } s.source_files = 'Classes/**/*' s.dependency 'Flutter' - s.dependency 'KlaviyoSwift', '~> 2.0.1' + s.dependency 'KlaviyoSwift', '~> 2.2.1' s.ios.deployment_target = '13.0' s.swift_version = '5.0' end diff --git a/pubspec.yaml b/pubspec.yaml index dc53a5b..367d019 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,11 +1,11 @@ name: klaviyo_flutter description: Flutter plugin for Klaviyo integration. Provides push messaging and Klaviyo analitics services -version: 0.0.2+3 +version: 0.0.3+1 homepage: https://github.com/drybnikov/klaviyo_flutter environment: - sdk: ">=2.18.0 <3.0.0" + sdk: ">=2.18.0 <4.0.0" flutter: ">=2.0.0" dependencies: