Skip to content

Commit

Permalink
feat: Update Clevertap SDK to 3.7.3
Browse files Browse the repository at this point in the history
  • Loading branch information
SuryaClevertap committed Apr 17, 2020
1 parent bd2b913 commit cbd819e
Show file tree
Hide file tree
Showing 98 changed files with 223 additions and 22 deletions.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file modified src/ios/CleverTapSDK.framework/CleverTapSDK
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
@import Foundation;
#import <Foundation/Foundation.h>
#import "CleverTap.h"

typedef void (^CleverTapExperimentsUpdatedBlock)(void);
Expand Down
158 changes: 158 additions & 0 deletions src/ios/CleverTapSDK.framework/Headers/CleverTap+DisplayUnit.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,158 @@
#import <Foundation/Foundation.h>
#import "CleverTap.h"
@class CleverTapDisplayUnitContent;

/*!
@abstract
The `CleverTapDisplayUnit` represents the display unit object.
*/
@interface CleverTapDisplayUnit : NSObject

- (instancetype _Nullable )initWithJSON:(NSDictionary *_Nullable)json;
/*!
* json defines the display unit data in the form of NSDictionary.
*/
@property (nullable, nonatomic, copy, readonly) NSDictionary *json;
/*!
* unitID defines the display unit identifier.
*/
@property (nullable, nonatomic, copy, readonly) NSString *unitID;
/*!
* type defines the display unit type.
*/
@property (nullable, nonatomic, copy, readonly) NSString *type;
/*!
* bgColor defines the backgroundColor of the display unit.
*/
@property (nullable, nonatomic, copy, readonly) NSString *bgColor;
/*!
* customExtras defines the extra data in the form of an NSDictionary. The extra key/value pairs set in the CleverTap dashboard.
*/
@property (nullable, nonatomic, copy, readonly) NSDictionary *customExtras;
/*!
* content defines the content of the display unit.
*/
@property (nullable, nonatomic, copy, readonly) NSArray<CleverTapDisplayUnitContent *> *contents;

@end

/*!
@abstract
The `CleverTapDisplayUnitContent` represents the display unit content.
*/
@interface CleverTapDisplayUnitContent : NSObject
/*!
* title defines the title section of the display unit content.
*/
@property (nullable, nonatomic, copy, readonly) NSString *title;
/*!
* titleColor defines hex-code value of the title color as String.
*/
@property (nullable, nonatomic, copy, readonly) NSString *titleColor;
/*!
* message defines the message section of the display unit content.
*/
@property (nullable, nonatomic, copy, readonly) NSString *message;
/*!
* messageColor defines hex-code value of the message color as String.
*/
@property (nullable, nonatomic, copy, readonly) NSString *messageColor;
/*!
* videoPosterUrl defines video URL of the display unit as String.
*/
@property (nullable, nonatomic, copy, readonly) NSString *videoPosterUrl;
/*!
* actionUrl defines action URL of the display unit as String.
*/
@property (nullable, nonatomic, copy, readonly) NSString *actionUrl;
/*!
* mediaUrl defines media URL of the display unit as String.
*/
@property (nullable, nonatomic, copy, readonly) NSString *mediaUrl;
/*!
* iconUrl defines icon URL of the display unit as String.
*/
@property (nullable, nonatomic, copy, readonly) NSString *iconUrl;
/*!
* mediaIsAudio check whether mediaUrl is an audio.
*/
@property (nonatomic, readonly, assign) BOOL mediaIsAudio;
/*!
* mediaIsVideo check whether mediaUrl is a video.
*/
@property (nonatomic, readonly, assign) BOOL mediaIsVideo;
/*!
* mediaIsImage check whether mediaUrl is an image.
*/
@property (nonatomic, readonly, assign) BOOL mediaIsImage;
/*!
* mediaIsGif check whether mediaUrl is a gif.
*/
@property (nonatomic, readonly, assign) BOOL mediaIsGif;

- (instancetype _Nullable )initWithJSON:(NSDictionary *_Nullable)jsonObject;

@end

@protocol CleverTapDisplayUnitDelegate <NSObject>
@optional
- (void)displayUnitsUpdated:(NSArray<CleverTapDisplayUnit *>*_Nonnull)displayUnits;
@end

typedef void (^CleverTapDisplayUnitSuccessBlock)(BOOL success);

@interface CleverTap (DisplayUnit)

/*!
@method
@abstract
This method returns all the display units.
*/
- (NSArray<CleverTapDisplayUnit *>*_Nonnull)getAllDisplayUnits;

/*!
@method
@abstract
This method return display unit for the provided unitID
*/
- (CleverTapDisplayUnit *_Nullable)getDisplayUnitForID:(NSString *_Nonnull)unitID;

/*!
@method
@abstract
The `CleverTapDisplayUnitDelegate` protocol provides methods for notifying
your application (the adopting delegate) about display units.
@discussion
This sets the CleverTapDisplayUnitDelegate.
@param delegate an object conforming to the CleverTapDisplayUnitDelegate Protocol
*/
- (void)setDisplayUnitDelegate:(id <CleverTapDisplayUnitDelegate>_Nonnull)delegate;

/*!
@method
@abstract
Record Notification Viewed for display unit.
@param unitID unique id of the display unit
*/
- (void)recordDisplayUnitViewedEventForID:(NSString *_Nonnull)unitID;

/*!
@method
@abstract
Record Notification Clicked for display unit.
@param unitID unique id of the display unit
*/
- (void)recordDisplayUnitClickedEventForID:(NSString *_Nonnull)unitID;

@end
34 changes: 34 additions & 0 deletions src/ios/CleverTapSDK.framework/Headers/CleverTap+Inbox.h
Original file line number Diff line number Diff line change
Expand Up @@ -173,6 +173,24 @@ typedef void (^CleverTapInboxUpdatedBlock)(void);

- (void)markReadInboxMessage:(CleverTapInboxMessage * _Nonnull) message;

/*!
@method
@abstract
This method deletes `CleverTapInboxMessage` object for the given `Message Id` as String.
*/

- (void)deleteInboxMessageForID:(NSString * _Nonnull)messageId;

/*!
@method
@abstract
This method marks the `CleverTapInboxMessage` object as read for given 'Message Id` as String.
*/

- (void)markReadInboxMessageForID:(NSString * _Nonnull)messageId;

/*!
@method
Expand All @@ -196,5 +214,21 @@ typedef void (^CleverTapInboxUpdatedBlock)(void);

- (CleverTapInboxViewController * _Nonnull)newInboxViewControllerWithConfig:(CleverTapInboxStyleConfig * _Nullable )config andDelegate:(id<CleverTapInboxViewControllerDelegate> _Nullable )delegate;

/*!
@method
@abstract
Record Notification Viewed for App Inbox.
*/
- (void)recordInboxNotificationViewedEventForID:(NSString * _Nonnull)messageId;

/*!
@method
@abstract
Record Notification Clicked for App Inbox.
*/
- (void)recordInboxNotificationClickedEventForID:(NSString * _Nonnull)messageId;


@end
1 change: 1 addition & 0 deletions src/ios/CleverTapSDK.framework/Headers/CleverTap.h
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
#define CLEVERTAP_NO_REACHABILITY_SUPPORT 1
#define CLEVERTAP_NO_INBOX_SUPPORT 1
#define CLEVERTAP_NO_AB_SUPPORT 1
#define CLEVERTAP_NO_DISPLAY_UNIT_SUPPORT 1
#endif

@protocol CleverTapSyncDelegate;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@

#define WR_SDK_REVISION @"30701"
#define WR_SDK_REVISION @"30703"
Binary file modified src/ios/CleverTapSDK.framework/Info.plist
Binary file not shown.
1 change: 1 addition & 0 deletions src/ios/CleverTapSDK.framework/Modules/module.modulemap
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ framework module CleverTapSDK {
header "CleverTap.h"
header "CleverTap+Inbox.h"
header "CleverTap+ABTesting.h"
header "CleverTap+DisplayUnit.h"
header "CleverTap+SSLPinning.h"
header "CleverTapBuildInfo.h"
header "CleverTapEventDetail.h"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ extern NSString *const kCTNotifViewedApiDomain;
#define CLTAP_INAPP_NOTIF_SHOW_CLOSE @"sc"
#define CLTAP_INAPP_JSON_RESPONSE_KEY @"inapp_notifs"
#define CLTAP_INBOX_MSG_JSON_RESPONSE_KEY @"inbox_notifs"
#define CLTAP_DISPLAY_UNIT_JSON_RESPONSE_KEY @"adUnit_notifs"
#define CLTAP_PREFS_INAPP_KEY @"inapp_notifs"
#define CLTAP_AB_EXP_JSON_RESPONSE_KEY @"ab_exps"
#define CLTAP_INAPP_CLOSE_IV_WIDTH 40
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
@class CTValidationResult;
@class CTInAppNotification;
@class CleverTapInboxMessage;
@class CleverTapDisplayUnit;

@interface CTEventBuilder : NSObject

Expand All @@ -27,4 +28,9 @@
andQueryParameters:(NSDictionary * _Nullable)params
completionHandler:(void(^ _Nonnull)(NSDictionary * _Nullable event, NSArray<CTValidationResult*> * _Nullable errors))completion;

+ (void)buildDisplayViewStateEvent:(BOOL)clicked
forDisplayUnit:(CleverTapDisplayUnit * _Nonnull)displayUnit
andQueryParameters:(NSDictionary * _Nullable)params
completionHandler:(void(^ _Nonnull)(NSDictionary * _Nullable event, NSArray<CTValidationResult*> * _Nullable errors))completion;

@end
40 changes: 20 additions & 20 deletions src/ios/CleverTapSDK.framework/PrivateHeaders/UIView+CTToast.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,11 +25,11 @@

#import <UIKit/UIKit.h>

extern const NSString * CSToastPositionTop;
extern const NSString * CSToastPositionCenter;
extern const NSString * CSToastPositionBottom;
extern const NSString * CTToastPositionTop;
extern const NSString * CTToastPositionCenter;
extern const NSString * CTToastPositionBottom;

@class CSToastStyle;
@class CTToastStyle;

/**
Toast is an Objective-C category that adds toast notifications to the UIView
Expand Down Expand Up @@ -77,7 +77,7 @@ extern const NSString * CSToastPositionBottom;
- (void)makeToast:(NSString *)message
duration:(NSTimeInterval)duration
position:(id)position
style:(CSToastStyle *)style;
style:(CTToastStyle *)style;

/**
Creates and presents a new toast view with a message, title, and image. Duration,
Expand All @@ -100,7 +100,7 @@ extern const NSString * CSToastPositionBottom;
position:(id)position
title:(NSString *)title
image:(UIImage *)image
style:(CSToastStyle *)style
style:(CTToastStyle *)style
completion:(void(^)(BOOL didTap))completion;

/**
Expand All @@ -120,7 +120,7 @@ extern const NSString * CSToastPositionBottom;
- (UIView *)toastViewForMessage:(NSString *)message
title:(NSString *)title
image:(UIImage *)image
style:(CSToastStyle *)style;
style:(CTToastStyle *)style;

/**
Hides the active toast. If there are multiple toasts active in a view, this method
Expand Down Expand Up @@ -209,16 +209,16 @@ extern const NSString * CSToastPositionBottom;
@end

/**
`CSToastStyle` instances define the look and feel for toast views created via the
`CTToastStyle` instances define the look and feel for toast views created via the
`makeToast:` methods as well for toast views created directly with
`toastViewForMessage:title:image:style:`.
@warning `CSToastStyle` offers relatively simple styling options for the default
@warning `CTToastStyle` offers relatively simple styling options for the default
toast view. If you require a toast view with more complex UI, it probably makes more
sense to create your own custom UIView subclass and present it with the `showToast:`
methods.
*/
@interface CSToastStyle : NSObject
@interface CTToastStyle : NSObject

/**
The background color. Default is `[UIColor blackColor]` at 80% opacity.
Expand Down Expand Up @@ -339,41 +339,41 @@ extern const NSString * CSToastPositionBottom;
@property (assign, nonatomic) NSTimeInterval fadeDuration;

/**
Creates a new instance of `CSToastStyle` with all the default values set.
Creates a new instance of `CTToastStyle` with all the default values set.
*/
- (instancetype)initWithDefaultStyle NS_DESIGNATED_INITIALIZER;

/**
@warning Only the designated initializer should be used to create
an instance of `CSToastStyle`.
an instance of `CTToastStyle`.
*/
- (instancetype)init NS_UNAVAILABLE;

@end

/**
`CSToastManager` provides general configuration options for all toast
`CTToastManager` provides general configuration options for all toast
notifications. Backed by a singleton instance.
*/
@interface CSToastManager : NSObject
@interface CTToastManager : NSObject

/**
Sets the shared style on the singleton. The shared style is used whenever
a `makeToast:` method (or `toastViewForMessage:title:image:style:`) is called
with with a nil style. By default, this is set to `CSToastStyle`'s default
with with a nil style. By default, this is set to `CTToastStyle`'s default
style.
@param sharedStyle the shared style
*/
+ (void)setSharedStyle:(CSToastStyle *)sharedStyle;
+ (void)setSharedStyle:(CTToastStyle *)sharedStyle;

/**
Gets the shared style from the singlton. By default, this is
`CSToastStyle`'s default style.
`CTToastStyle`'s default style.
@return the shared style
*/
+ (CSToastStyle *)sharedStyle;
+ (CTToastStyle *)sharedStyle;

/**
Enables or disables tap to dismiss on toast views. Default is `YES`.
Expand Down Expand Up @@ -428,15 +428,15 @@ extern const NSString * CSToastPositionBottom;
/**
Sets the default position. Used for the `makeToast:` and
`showToast:` methods that don't require an explicit position.
Default is `CSToastPositionBottom`.
Default is `CTToastPositionBottom`.
@param position The default center point. Can be one of the predefined
CSToastPosition constants or a `CGPoint` wrapped in an `NSValue` object.
*/
+ (void)setDefaultPosition:(id)position;

/**
Returns the default toast position. Default is `CSToastPositionBottom`.
Returns the default toast position. Default is `CTToastPositionBottom`.
@return position The default center point. Will be one of the predefined
CSToastPosition constants or a `CGPoint` wrapped in an `NSValue` object.
Expand Down

0 comments on commit cbd819e

Please sign in to comment.