diff --git a/README.md b/README.md index 78c8ee8..d753ae4 100644 --- a/README.md +++ b/README.md @@ -75,30 +75,36 @@ in your App.js: ```javascript -import { - Alert -} from 'react-native'; - +import { Text} from 'react-native'; +import React, { Component } from 'react'; import Pushbots from 'pushbots-react-native' -Pushbots.registerForRemoteNotifications() -export default class App extends Component<{}> { - componentWillMount() { - Pushbots.addEventListener('received', this.onReceived); - Pushbots.addEventListener('opened', this.onOpened); - } - componentWillUnmount() { - Pushbots.removeEventListener('received', this.onReceived); - Pushbots.removeEventListener('opened', this.onOpened); } - onReceived(notification) { - Alert.alert( 'Received Notification', JSON.stringify(notification), [ {text: 'Ask me later', onPress: () => console.log('Ask me later pressed')}, {text: 'Cancel', onPress: () => console.log('Cancel Pressed'), style: 'cancel'}, {text: 'OK', onPress: () => console.log('OK Pressed')}, ], { cancelable: false } ) - } - onOpened(notification) { - Alert.alert( 'Opened Notification', JSON.stringify(notification), [ {text: 'Ask me later', onPress: () => console.log('Ask me later pressed')}, {text: 'Cancel', onPress: () => console.log('Cancel Pressed'), style: 'cancel'}, {text: 'OK', onPress: () => console.log('OK Pressed')}, ], { cancelable: false } ) - } +Pushbots.registerForRemoteNotifications() +export default class App extends Component { + constructor(properties) { + super(properties); + Pushbots.addEventListener('received', this.onReceived); + Pushbots.addEventListener('opened', this.onOpened); + } + componentWillUnmount() { + Pushbots.removeEventListener('received', this.onReceived); + Pushbots.removeEventListener('opened', this.onOpened); } + + onReceived(notification) { + console.log('Received Notification: ', notification); + } + onOpened(notification) { + console.log('Opened Notification: ', notification); + } + render() { + return ( + Hello From Pushbots + ); + } } + ``` ## Contributors diff --git a/android/src/.DS_Store b/android/src/.DS_Store index 0787fb7..bf54e88 100644 Binary files a/android/src/.DS_Store and b/android/src/.DS_Store differ diff --git a/android/src/main/.DS_Store b/android/src/main/.DS_Store index 63b728b..7204f7e 100644 Binary files a/android/src/main/.DS_Store and b/android/src/main/.DS_Store differ diff --git a/android/src/main/java/.DS_Store b/android/src/main/java/.DS_Store index 0a8bc21..2d7b91d 100644 Binary files a/android/src/main/java/.DS_Store and b/android/src/main/java/.DS_Store differ diff --git a/android/src/main/java/com/.DS_Store b/android/src/main/java/com/.DS_Store index 86d6f34..99db156 100644 Binary files a/android/src/main/java/com/.DS_Store and b/android/src/main/java/com/.DS_Store differ diff --git a/android/src/main/java/com/pushbots/.DS_Store b/android/src/main/java/com/pushbots/.DS_Store index 47de3d8..a045d06 100644 Binary files a/android/src/main/java/com/pushbots/.DS_Store and b/android/src/main/java/com/pushbots/.DS_Store differ diff --git a/index.js b/index.js index 319fff8..56eb179 100644 --- a/index.js +++ b/index.js @@ -1,22 +1,23 @@ -import { NativeModules, NativeAppEventEmitter, Platform } from 'react-native'; +import { NativeModules, NativeEventEmitter, Platform } from 'react-native'; const RNPushbotsModule = NativeModules.Pushbots; const not_handlers = new Map(); +const eventEmitter = new NativeEventEmitter(RNPushbotsModule); export default class Pushbots { static addEventListener(type: any, handler: Function) { var listener; if (type === 'received') { - listener = NativeAppEventEmitter.addListener( + listener = eventEmitter.addListener( 'Pushbots__RemoteNotificationReceived', (notification) => { handler(notification); } ); }else if (type === 'opened') { - listener = NativeAppEventEmitter.addListener( + listener = eventEmitter.addListener( 'Pushbots__RemoteNotificationOpened', (notification) => { handler(notification); @@ -126,4 +127,4 @@ export default class Pushbots { RNPushbotsModule.clearBadgeCount() } } -} +} \ No newline at end of file diff --git a/ios/.DS_Store b/ios/.DS_Store index dfeafca..df2bd0e 100644 Binary files a/ios/.DS_Store and b/ios/.DS_Store differ diff --git a/ios/Pushbots.framework/CloseButton.png b/ios/Pushbots.framework/CloseButton.png new file mode 100644 index 0000000..c671ad8 Binary files /dev/null and b/ios/Pushbots.framework/CloseButton.png differ diff --git a/ios/Pushbots.framework/CloseButton@2x.png b/ios/Pushbots.framework/CloseButton@2x.png new file mode 100644 index 0000000..cbfe7ec Binary files /dev/null and b/ios/Pushbots.framework/CloseButton@2x.png differ diff --git a/ios/Pushbots.framework/CloseButton@3x.png b/ios/Pushbots.framework/CloseButton@3x.png new file mode 100644 index 0000000..1a0b177 Binary files /dev/null and b/ios/Pushbots.framework/CloseButton@3x.png differ diff --git a/ios/Pushbots.h b/ios/Pushbots.framework/Headers/Pushbots.h old mode 100755 new mode 100644 similarity index 89% rename from ios/Pushbots.h rename to ios/Pushbots.framework/Headers/Pushbots.h index a2baaaa..6e52453 --- a/ios/Pushbots.h +++ b/ios/Pushbots.framework/Headers/Pushbots.h @@ -11,7 +11,7 @@ /*! @class - PushBots SDK v2.1.2 + PushBots SDK v2.4.6 @abstract The primary interface for integrating PushBots with your app. @@ -43,6 +43,11 @@ typedef NS_ENUM(NSUInteger, PBLogLevel) { typedef void (^PushBotsReceivedNotification)(NSDictionary * result); typedef void (^PushBotsOpenedNotification)(NSDictionary * result); +typedef void (^PushBotsRegistered)(NSString * userid); + ++ (void) onRegistered:(PushBotsRegistered)rCallback; + + /*! @method @@ -103,7 +108,7 @@ typedef void (^PushBotsOpenedNotification)(NSDictionary * result); */ + (void)setLogLevel:(PBLogLevel)pbloglevel; - ++ (void)setLogLevel:(PBLogLevel)pbloglevel isUILog:(BOOL)uiLog; /*! @method @@ -138,6 +143,8 @@ Show prompt to register with remote notifications. @param callback callback block to get device data as NSDictionary */ + (void) getDevice:(void (^)(NSDictionary *device, NSError *error))callback; ++ (void) checkInApp:(void (^)(NSArray *inappmessages, NSError *error))callback; ++(void) inAppNotificationOpenedWithId:(NSString *) inapp_id; /*! @method @@ -183,6 +190,14 @@ This method will toggle debug mode on the device, visit sandbox section in dashb */ + (void) setAlias:(NSString *)alias; ++ (void) setName:(NSString *)name; ++ (void) setFirstName:(NSString *)f_name; ++ (void) setLastName:(NSString *)l_name; ++ (void) setEmail:(NSString *)email; ++ (void) setGender:(NSString *)gender; ++ (void) setPhone:(NSString *)phone; + + /*! @method @@ -264,6 +279,9 @@ This method will toggle debug mode on the device, visit sandbox section in dashb */ + (void) toggleNotifications:(BOOL)subscribed; ++ (BOOL)showTakeoverNotificationWithObject:(NSDictionary *) notification; ++ (void)showTakeoverNotificationWith:(NSDictionary *) notification; ++ (BOOL) validateInAppMessage:(NSDictionary *) message; + (void) trackPushNotificationOpenedWithLaunchOptions:(NSDictionary *) launchOptions; + (void) trackPushNotificationOpenedWithPayload:(NSDictionary *) payload; @@ -271,7 +289,8 @@ This method will toggle debug mode on the device, visit sandbox section in dashb +(void) trackEvent:(NSString *)event; +(void) trackEvent:(NSString *)event withValue:(NSString *)value; - ++(void) shareLocation:(BOOL)isSharingEnabled; ++(void) shareLocationPrompt:(BOOL)isPrompt; #pragma clang diagnostic push #pragma clang diagnostic ignored "-Wunguarded-availability" #ifdef IOS10PLUS @@ -279,6 +298,7 @@ This method will toggle debug mode on the device, visit sandbox section in dashb // Notification Service Extension + (UNMutableNotificationContent*)didReceiveNotificationExtensionRequest:(UNNotificationRequest*)request withContent:(UNMutableNotificationContent*)replacementContent; + (UNMutableNotificationContent*)serviceExtensionTimeWillExpireRequest:(UNNotificationRequest*)request withContent:(UNMutableNotificationContent*)replacementContent; + #endif #pragma clang diagnostic pop diff --git a/ios/Pushbots.framework/Info.plist b/ios/Pushbots.framework/Info.plist new file mode 100644 index 0000000..72c9007 Binary files /dev/null and b/ios/Pushbots.framework/Info.plist differ diff --git a/ios/Pushbots.framework/Modules/module.modulemap b/ios/Pushbots.framework/Modules/module.modulemap new file mode 100644 index 0000000..0217fb6 --- /dev/null +++ b/ios/Pushbots.framework/Modules/module.modulemap @@ -0,0 +1,6 @@ +framework module Pushbots { + umbrella header "Pushbots.h" + + export * + module * { export * } +} diff --git a/ios/Pushbots.framework/Pushbots b/ios/Pushbots.framework/Pushbots new file mode 100644 index 0000000..32f0ca7 Binary files /dev/null and b/ios/Pushbots.framework/Pushbots differ diff --git a/ios/Pushbots.framework/Versions/A/Headers/Pushbots.h b/ios/Pushbots.framework/Versions/A/Headers/Pushbots.h new file mode 100644 index 0000000..6e52453 --- /dev/null +++ b/ios/Pushbots.framework/Versions/A/Headers/Pushbots.h @@ -0,0 +1,305 @@ +#import +#import + +//Use UserNotifications with iOS 10+ +#if __IPHONE_OS_VERSION_MAX_ALLOWED >= 100000 +#define IOS10PLUS 1 +#import +#endif + +@class Pushbots; + +/*! + @class + PushBots SDK v2.4.6 + @abstract + The primary interface for integrating PushBots with your app. + +
+//in AppDelegate.h:
+@property (strong, nonatomic) Pushbots *PushbotsClient;
+//in AppDelegate.m
+ NSString *appID =  @"56c3515f357e71aa0a0";
+ self.PushbotsClient = [Pushbots sharedInstanceWithAppId:appID andLoggingEnabled:YES];
+ 
+ + For more advanced usage, please see the PushBots iOS SDK integration. + */ + + +@interface Pushbots : NSObject +/** + * Pushbots log levels. + */ +typedef NS_ENUM(NSUInteger, PBLogLevel) { + PBLogLevelNoLogging, PBLogLevelError, PBLogLevelWarn, PBLogLevelInfo, PBLogLevelVerbose +}; ++ (NSDictionary*) currentlyShowingNotification; ++ (NSString*)applicationId; ++ (NSString*)deviceId; ++ (BOOL) prompt; ++ (BOOL) receivedCallback; + +typedef void (^PushBotsReceivedNotification)(NSDictionary * result); +typedef void (^PushBotsOpenedNotification)(NSDictionary * result); +typedef void (^PushBotsRegistered)(NSString * userid); + ++ (void) onRegistered:(PushBotsRegistered)rCallback; + + +/*! + @method + + @abstract + Initializes an instance of the API. + + @discussion + Initializes an instance of the PushBots. + + @param appId Pushbots Application ID. + @param launchOptions launchOptions + */ ++(id)initWithAppId:(NSString*)appId withLaunchOptions:(NSDictionary *)launchOptions; + +/*! + @method + + @abstract + Initializes an instance of the API. + + @discussion + Initializes an instance of the PushBots. + + @param appId Pushbots Application ID. + @param launchOptions launchOptions + @param prompt Push notification prompt on first app open. + + */ ++ (id)initWithAppId:(NSString*)appId withLaunchOptions:(NSDictionary *)launchOptions prompt:(BOOL)prompt; ++ (id)initWithAppId:(NSString*)appId withLaunchOptions:(NSDictionary *)launchOptions prompt:(BOOL)p receivedNotification:(PushBotsReceivedNotification)rCallback openedNotification:(PushBotsOpenedNotification)oCallback; + +/*! + @method + + @abstract + Initializes an instance of the API. + + @discussion + Initializes an instance of the PushBots. + + @param appId Pushbots Application ID. + @param launchOptions launchOptions + @param p Push notification prompt on first app open. + @param rCallback block to access notification data on received. + */ ++ (id)initWithAppId:(NSString*)appId withLaunchOptions:(NSDictionary *)launchOptions prompt:(BOOL)p receivedNotification:(PushBotsReceivedNotification)rCallback; + + ++ (void)notificationReceived:(NSDictionary*)messageDict; +/*! + @method + + @discussion + Set PuhsBots SDK log level +
[Pushbots setLogLevel:PBLogLevelVerbose];
+ + @param pbloglevel PBLogLevelNoLogging, PBLogLevelVerbose, PBLogLevelInfo, PBLogLevelWarn, PBLogLevelError + + */ ++ (void)setLogLevel:(PBLogLevel)pbloglevel; ++ (void)setLogLevel:(PBLogLevel)pbloglevel isUILog:(BOOL)uiLog; +/*! + @method + + @discussion +Show prompt to register with remote notifications. + */ ++ (void)registerForRemoteNotifications; + + +/*! + @method + + @abstract + Registers device with all its data on PushBots servers, and increment sessions count, updates last session date. + + @discussion + This method should be called in application:didRegisterForRemoteNotificationsWithDeviceToken: to register the device on PushBots servers. + + @param deviceToken Device token from Apple servers. + */ ++ (void) registerOnPushbots:(NSData *)deviceToken; + +/*! + @method + + @abstract + Get device data from Pushbots. + + @discussion + This method will request device data from PushBots servers, should be used to sync tags/alias. + + @param callback callback block to get device data as NSDictionary + */ ++ (void) getDevice:(void (^)(NSDictionary *device, NSError *error))callback; ++ (void) checkInApp:(void (^)(NSArray *inappmessages, NSError *error))callback; ++(void) inAppNotificationOpenedWithId:(NSString *) inapp_id; + +/*! + @method + + @abstract +Update device data on Pushbots. + + @discussion + This method will update device data on PushBots. + Device data keys: + tags: (array) set device tags. + tags_add: (array) add tags. + tags_remove: (array) remove tags. + alias: (String) set device alias. + badge: (Integer) set device badge. + badge_p: (Integer) Increment device badge. + badge_d: (Integet) decrement device badge. + debug: (Boolean) Set device debug status for sandbox. + subscribed: (Boolean) subscribe/unsubscribe from Push notifications. + location: (array)[lat, lng] update device location. + + @param deviceObject NSDictionary with device data to be updated. + */ ++ (void) update:(NSDictionary *)deviceObject; + +/*! + @method + + @discussion +This method will toggle debug mode on the device, visit sandbox section in dashboard for more details. + + @param debug Toggle debug mode for sandboxing. + */ ++ (void) debug:(BOOL)debug; + +/*! + @method + + @discussion + This method will update device alias on PushBots. + + @param alias device alias. + */ ++ (void) setAlias:(NSString *)alias; + ++ (void) setName:(NSString *)name; ++ (void) setFirstName:(NSString *)f_name; ++ (void) setLastName:(NSString *)l_name; ++ (void) setEmail:(NSString *)email; ++ (void) setGender:(NSString *)gender; ++ (void) setPhone:(NSString *)phone; + + + +/*! + @method + + @discussion + This method will remove device alias from PushBots. + + */ ++ (void) removeAlias; + + +/*! + @method + + @discussion + This method will add tags to the device info. + + @param tags Array of device tags to be added to the device. + */ ++ (void) tag:(NSArray *)tags; + +/*! + @method + + @discussion + This method will remove tags from device info. + + @param tags Array of device tags to be removed from the device. + */ ++ (void) untag:(NSArray *)tags; + +/*! + @method + + @discussion + This method will set badge count on Pushbots and in the app (applicationIconBadgeNumber). + + @param number New badge count. + */ ++ (void) setBadge: (int) number; + +/*! + @method + + @discussion + This method will increment badge count on PushBots and in the app (applicationIconBadgeNumber). + + @param number badge count to add. + */ ++ (void) incrementBadgeCountBy: (int) number; + +/*! + @method + + @discussion + This method will decrement badge count on PushBots and in the app (applicationIconBadgeNumber). + + @param number badge count to substract. + */ ++ (void) decrementBadgeCountBy: (int) number; + +/*! + @method + + @discussion + This method will Clear badge count on PushBots and in the app (applicationIconBadgeNumber). + + */ ++ (void) clearBadgeCount; + ++ (void)openURL:(NSDictionary *)userInfo; + +/*! + @method + + @discussion + This method will toggle Push notification subscription status. + @param subscribed badge count to substract. + + */ ++ (void) toggleNotifications:(BOOL)subscribed; ++ (BOOL)showTakeoverNotificationWithObject:(NSDictionary *) notification; ++ (void)showTakeoverNotificationWith:(NSDictionary *) notification; ++ (BOOL) validateInAppMessage:(NSDictionary *) message; + ++ (void) trackPushNotificationOpenedWithLaunchOptions:(NSDictionary *) launchOptions; ++ (void) trackPushNotificationOpenedWithPayload:(NSDictionary *) payload; ++ (void) trackPushNotificationOpenedWithPoll:(NSDictionary *) payload andAnswerId:(NSString *)ansewerID sync:(BOOL) sync; + ++(void) trackEvent:(NSString *)event; ++(void) trackEvent:(NSString *)event withValue:(NSString *)value; ++(void) shareLocation:(BOOL)isSharingEnabled; ++(void) shareLocationPrompt:(BOOL)isPrompt; +#pragma clang diagnostic push +#pragma clang diagnostic ignored "-Wunguarded-availability" +#ifdef IOS10PLUS +// iOS 10 only +// Notification Service Extension ++ (UNMutableNotificationContent*)didReceiveNotificationExtensionRequest:(UNNotificationRequest*)request withContent:(UNMutableNotificationContent*)replacementContent; ++ (UNMutableNotificationContent*)serviceExtensionTimeWillExpireRequest:(UNNotificationRequest*)request withContent:(UNMutableNotificationContent*)replacementContent; + +#endif +#pragma clang diagnostic pop + +@end diff --git a/ios/Pushbots.framework/Versions/A/Modules/module.modulemap b/ios/Pushbots.framework/Versions/A/Modules/module.modulemap new file mode 100644 index 0000000..adc5736 --- /dev/null +++ b/ios/Pushbots.framework/Versions/A/Modules/module.modulemap @@ -0,0 +1,5 @@ +framework module Pushbots { + umbrella header "Pushbots.h" + export * + module * { export * } +} diff --git a/ios/Pushbots.framework/Versions/A/Pushbots b/ios/Pushbots.framework/Versions/A/Pushbots new file mode 100644 index 0000000..32f0ca7 Binary files /dev/null and b/ios/Pushbots.framework/Versions/A/Pushbots differ diff --git a/ios/Pushbots.framework/Versions/Current b/ios/Pushbots.framework/Versions/Current new file mode 100644 index 0000000..7d27390 Binary files /dev/null and b/ios/Pushbots.framework/Versions/Current differ diff --git a/ios/Pushbots.framework/inAppMessageLayout~ipad.nib/objects-13.0+.nib b/ios/Pushbots.framework/inAppMessageLayout~ipad.nib/objects-13.0+.nib new file mode 100644 index 0000000..1dac864 Binary files /dev/null and b/ios/Pushbots.framework/inAppMessageLayout~ipad.nib/objects-13.0+.nib differ diff --git a/ios/Pushbots.framework/inAppMessageLayout~ipad.nib/runtime.nib b/ios/Pushbots.framework/inAppMessageLayout~ipad.nib/runtime.nib new file mode 100644 index 0000000..cfa2c0c Binary files /dev/null and b/ios/Pushbots.framework/inAppMessageLayout~ipad.nib/runtime.nib differ diff --git a/ios/Pushbots.framework/inAppMessageLayout~landscape.nib/objects-13.0+.nib b/ios/Pushbots.framework/inAppMessageLayout~landscape.nib/objects-13.0+.nib new file mode 100644 index 0000000..8718e69 Binary files /dev/null and b/ios/Pushbots.framework/inAppMessageLayout~landscape.nib/objects-13.0+.nib differ diff --git a/ios/Pushbots.framework/inAppMessageLayout~landscape.nib/runtime.nib b/ios/Pushbots.framework/inAppMessageLayout~landscape.nib/runtime.nib new file mode 100644 index 0000000..7bc63fb Binary files /dev/null and b/ios/Pushbots.framework/inAppMessageLayout~landscape.nib/runtime.nib differ diff --git a/ios/Pushbots.framework/inAppMessageLayout~portrait.nib/objects-13.0+.nib b/ios/Pushbots.framework/inAppMessageLayout~portrait.nib/objects-13.0+.nib new file mode 100644 index 0000000..936e4d2 Binary files /dev/null and b/ios/Pushbots.framework/inAppMessageLayout~portrait.nib/objects-13.0+.nib differ diff --git a/ios/Pushbots.framework/inAppMessageLayout~portrait.nib/runtime.nib b/ios/Pushbots.framework/inAppMessageLayout~portrait.nib/runtime.nib new file mode 100644 index 0000000..e8104f5 Binary files /dev/null and b/ios/Pushbots.framework/inAppMessageLayout~portrait.nib/runtime.nib differ diff --git a/ios/Pushbots.framework/placeholder-image.png b/ios/Pushbots.framework/placeholder-image.png new file mode 100644 index 0000000..6ec8b86 Binary files /dev/null and b/ios/Pushbots.framework/placeholder-image.png differ diff --git a/ios/RCTPushbots.h b/ios/RCTPushbots.h index 7f1751b..88bfeb4 100644 --- a/ios/RCTPushbots.h +++ b/ios/RCTPushbots.h @@ -10,8 +10,10 @@ #else #import "Pushbots.h" #endif - -@interface RCTPushbots : NSObject +#import +@import WebKit; +@import CoreTelephony; +@interface RCTPushbots : RCTEventEmitter - (id) initWithAppId:(NSString*)appId withLaunchOptions:(NSDictionary *)launchOptions; - (id) initWithAppId:(NSString*)appId withLaunchOptions:(NSDictionary *)launchOptions prompt:(BOOL)prompt; @end diff --git a/ios/RCTPushbots.m b/ios/RCTPushbots.m index 899d511..8c2046f 100644 --- a/ios/RCTPushbots.m +++ b/ios/RCTPushbots.m @@ -23,20 +23,23 @@ @interface RCTPushbots () @implementation RCTPushbots -@synthesize bridge = _bridge; - RCT_EXPORT_MODULE() -static RCTBridge *curRCTBridge; - -- (void)setBridge:(RCTBridge *)receivedBridge { - _bridge = receivedBridge; - curRCTBridge = receivedBridge; -} - - (void)dealloc { [[NSNotificationCenter defaultCenter] removeObserver:self]; } ++ (instancetype)alloc{ + static RCTPushbots *sharedInstance = nil; + static dispatch_once_t onceToken; + dispatch_once(&onceToken, ^{ + sharedInstance = [super allocWithZone:nil]; + }); + return sharedInstance; +} +- (NSArray *)supportedEvents +{ + return @[@"Pushbots__RemoteNotificationReceived", @"Pushbots__RemoteNotificationOpened"]; +} - (id) initWithAppId:(NSString*)appId withLaunchOptions:(NSDictionary *)launchOptions; { NSLog(@"initWithAppId:"); @@ -45,7 +48,11 @@ - (id) initWithAppId:(NSString*)appId withLaunchOptions:(NSDictionary *)launchOp - (id) initWithAppId:(NSString*)appId withLaunchOptions:(NSDictionary *)launchOptions prompt:(BOOL)prompt{ [Pushbots initWithAppId:appId withLaunchOptions:launchOptions prompt:prompt receivedNotification:^(NSDictionary *result) { - [curRCTBridge.eventDispatcher sendAppEventWithName:@"Pushbots__RemoteNotificationReceived" body:result]; + [self sendEventWithName:@"Pushbots__RemoteNotificationReceived" body: result]; + + } openedNotification:^(NSDictionary *result) { + [self sendEventWithName:@"Pushbots__RemoteNotificationOpened" body: result]; + }]; return self; } @@ -96,8 +103,7 @@ - (id) initWithAppId:(NSString*)appId withLaunchOptions:(NSDictionary *)launchOp RCT_EXPORT_METHOD(registerForRemoteNotifications) { - [Pushbots registerForRemoteNotifications]; - curRCTBridge = self.bridge; + } diff --git a/ios/RCTPushbots.xcodeproj/project.pbxproj b/ios/RCTPushbots.xcodeproj/project.pbxproj index 5264a8c..74a5e34 100644 --- a/ios/RCTPushbots.xcodeproj/project.pbxproj +++ b/ios/RCTPushbots.xcodeproj/project.pbxproj @@ -8,7 +8,6 @@ /* Begin PBXBuildFile section */ BA89F5B4205BDE6D00ABDE84 /* libRCTPushbots.a in Copy Files */ = {isa = PBXBuildFile; fileRef = 134814201AA4EA6300B7C361 /* libRCTPushbots.a */; }; - BA89F5C8205BE0B000ABDE84 /* libPushbots.a in Frameworks */ = {isa = PBXBuildFile; fileRef = BA89F5C7205BE0B000ABDE84 /* libPushbots.a */; }; BA902CEF1FBDB18600574058 /* RCTPushbots.m in Sources */ = {isa = PBXBuildFile; fileRef = B3E7B5891CC2AC0600A0062D /* RCTPushbots.m */; }; /* End PBXBuildFile section */ @@ -31,7 +30,6 @@ B3E7B5881CC2AC0600A0062D /* RCTPushbots.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTPushbots.h; sourceTree = ""; }; B3E7B5891CC2AC0600A0062D /* RCTPushbots.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTPushbots.m; sourceTree = ""; }; BA89F5B7205BDE9D00ABDE84 /* Pushbots.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = Pushbots.h; sourceTree = ""; }; - BA89F5C7205BE0B000ABDE84 /* libPushbots.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; path = libPushbots.a; sourceTree = ""; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ @@ -39,7 +37,6 @@ isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( - BA89F5C8205BE0B000ABDE84 /* libPushbots.a in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -54,13 +51,20 @@ name = Products; sourceTree = ""; }; + 52B07AD62448DD3A000EF4B8 /* Frameworks */ = { + isa = PBXGroup; + children = ( + ); + path = Frameworks; + sourceTree = ""; + }; 58B511D21A9E6C8500147676 = { isa = PBXGroup; children = ( - BA89F5C7205BE0B000ABDE84 /* libPushbots.a */, BA89F5B7205BDE9D00ABDE84 /* Pushbots.h */, B3E7B5881CC2AC0600A0062D /* RCTPushbots.h */, B3E7B5891CC2AC0600A0062D /* RCTPushbots.m */, + 52B07AD62448DD3A000EF4B8 /* Frameworks */, 134814211AA4EA7D00B7C361 /* Products */, ); sourceTree = ""; @@ -104,6 +108,7 @@ developmentRegion = English; hasScannedForEncodings = 0; knownRegions = ( + English, en, ); mainGroup = 58B511D21A9E6C8500147676; diff --git a/ios/RCTPushbots.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist b/ios/RCTPushbots.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist new file mode 100644 index 0000000..18d9810 --- /dev/null +++ b/ios/RCTPushbots.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist @@ -0,0 +1,8 @@ + + + + + IDEDidComputeMac32BitWarning + + + diff --git a/ios/RCTPushbots.xcodeproj/project.xcworkspace/xcuserdata/macbookpro.xcuserdatad/UserInterfaceState.xcuserstate b/ios/RCTPushbots.xcodeproj/project.xcworkspace/xcuserdata/macbookpro.xcuserdatad/UserInterfaceState.xcuserstate new file mode 100644 index 0000000..f024880 Binary files /dev/null and b/ios/RCTPushbots.xcodeproj/project.xcworkspace/xcuserdata/macbookpro.xcuserdatad/UserInterfaceState.xcuserstate differ diff --git a/ios/RCTPushbots.xcodeproj/xcuserdata/macbookpro.xcuserdatad/xcschemes/xcschememanagement.plist b/ios/RCTPushbots.xcodeproj/xcuserdata/macbookpro.xcuserdatad/xcschemes/xcschememanagement.plist new file mode 100644 index 0000000..c7e450a --- /dev/null +++ b/ios/RCTPushbots.xcodeproj/xcuserdata/macbookpro.xcuserdatad/xcschemes/xcschememanagement.plist @@ -0,0 +1,14 @@ + + + + + SchemeUserState + + RCTPushbots.xcscheme_^#shared#^_ + + orderHint + 0 + + + + diff --git a/ios/libPushbots.a b/ios/libPushbots.a deleted file mode 100644 index 0ef9260..0000000 Binary files a/ios/libPushbots.a and /dev/null differ diff --git a/pushbots-react-native.podspec b/pushbots-react-native.podspec index c030151..6515eb1 100644 --- a/pushbots-react-native.podspec +++ b/pushbots-react-native.podspec @@ -13,5 +13,5 @@ Pod::Spec.new do |s| s.static_framework = true s.platform = :ios, "10.0" s.dependency 'React', '>= 0.13.0', '< 1.0.0' - s.dependency 'Pushbots', '2.4.3' + s.vendored_frameworks = 'ios/Pushbots.framework' end \ No newline at end of file