zixflow-reactnative 1.0.0 → 1.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +1 -1
- package/README.md +8 -8
- package/android/build.gradle +4 -13
- package/android/gradle.properties +1 -1
- package/android/src/main/AndroidManifest.xml +5 -5
- package/android/src/main/java/{io/customer/reactnative/sdk/NativeCustomerIOModule.kt → com/zixflow/reactnative/sdk/NativeZixflowModule.kt} +35 -35
- package/android/src/main/java/{io/customer/reactnative/sdk/CustomerIOReactNativePackage.kt → com/zixflow/reactnative/sdk/ZixflowReactNativePackage.kt} +15 -15
- package/android/src/main/java/{io/customer → com/zixflow}/reactnative/sdk/constant/Keys.kt +1 -1
- package/android/src/main/java/{io/customer → com/zixflow}/reactnative/sdk/extension/MapExtensions.kt +1 -1
- package/android/src/main/java/{io/customer → com/zixflow}/reactnative/sdk/extension/ReactExtensions.kt +1 -1
- package/android/src/main/java/{io/customer → com/zixflow}/reactnative/sdk/extension/StringExtensions.kt +1 -1
- package/android/src/main/java/{io/customer → com/zixflow}/reactnative/sdk/extension/ViewExtensions.kt +1 -1
- package/android/src/main/java/{io/customer → com/zixflow}/reactnative/sdk/location/NativeLocationModule.kt +15 -15
- package/android/src/main/java/{io/customer/reactnative/sdk/logging/NativeCustomerIOLoggingModule.kt → com/zixflow/reactnative/sdk/logging/NativeZixflowLoggingModule.kt} +10 -10
- package/android/src/main/java/{io/customer → com/zixflow}/reactnative/sdk/messaginginapp/InlineInAppMessageViewManager.kt +2 -2
- package/android/src/main/java/{io/customer → com/zixflow}/reactnative/sdk/messaginginapp/NativeMessagingInAppModule.kt +26 -26
- package/android/src/main/java/{io/customer → com/zixflow}/reactnative/sdk/messaginginapp/NotificationInboxExtensions.kt +5 -5
- package/android/src/main/java/{io/customer → com/zixflow}/reactnative/sdk/messaginginapp/ReactInAppEventListener.kt +4 -4
- package/android/src/main/java/{io/customer → com/zixflow}/reactnative/sdk/messaginginapp/ReactInAppPlatformDelegate.kt +3 -3
- package/android/src/main/java/{io/customer → com/zixflow}/reactnative/sdk/messaginginapp/ReactInlineInAppMessageView.kt +5 -5
- package/android/src/main/java/{io/customer → com/zixflow}/reactnative/sdk/messaginginapp/ReactNotificationInboxChangeListener.kt +3 -3
- package/android/src/main/java/{io/customer → com/zixflow}/reactnative/sdk/messagingpush/NativeMessagingPushModule.kt +25 -25
- package/android/src/main/java/{io/customer → com/zixflow}/reactnative/sdk/messagingpush/PermissionStatus.kt +1 -1
- package/android/src/main/java/{io/customer → com/zixflow}/reactnative/sdk/messagingpush/PushMessagingExtensions.kt +2 -2
- package/android/src/main/java/{io/customer → com/zixflow}/reactnative/sdk/util/Preconditions.kt +3 -3
- package/android/src/main/res/values/{customer_io_config.xml → zixflow_config.xml} +2 -2
- package/ios/wrappers/{NativeCustomerIO.mm → NativeZixflow.mm} +9 -9
- package/ios/wrappers/{NativeCustomerIO.swift → NativeZixflow.swift} +31 -31
- package/ios/wrappers/inapp/InboxMessage+Conversion.swift +1 -1
- package/ios/wrappers/inapp/NativeMessagingInApp.mm +8 -8
- package/ios/wrappers/inapp/NativeMessagingInApp.swift +7 -7
- package/ios/wrappers/inapp/ReactInAppEventListener.swift +12 -12
- package/ios/wrappers/inapp/inline/ReactInlineMessageView.swift +1 -1
- package/ios/wrappers/location/NativeLocation.mm +8 -8
- package/ios/wrappers/location/NativeLocation.swift +6 -6
- package/ios/wrappers/logging/{NativeCustomerIOLogging.mm → NativeZixflowLogging.mm} +14 -14
- package/ios/wrappers/logging/{NativeCustomerIOLogging.swift → NativeZixflowLogging.swift} +6 -6
- package/ios/wrappers/push/NativeMessagingPush.mm +8 -8
- package/ios/wrappers/push/NativeMessagingPush.swift +12 -12
- package/ios/wrappers/utils/Preconditions.swift +1 -1
- package/ios/wrappers/utils/{RCTCustomerIOUtils.h → RCTZixflowUtils.h} +3 -3
- package/ios/wrappers/utils/{CioConfigUtils.swift → ZixflowConfigUtils.swift} +4 -4
- package/ios/wrappers/utils/{CioConstants.swift → ZixflowConstants.swift} +4 -4
- package/lib/commonjs/native-logger-listener.js +10 -10
- package/lib/commonjs/native-logger-listener.js.map +1 -1
- package/lib/commonjs/notification-inbox.js +4 -4
- package/lib/commonjs/notification-inbox.js.map +1 -1
- package/lib/commonjs/postInstall.js +1 -1
- package/lib/commonjs/postInstall.js.map +1 -1
- package/lib/commonjs/specs/modules/{NativeCustomerIO.js → NativeZixflow.js} +6 -6
- package/lib/commonjs/specs/modules/NativeZixflow.js.map +1 -0
- package/lib/commonjs/specs/modules/{NativeCustomerIOLocation.js → NativeZixflowLocation.js} +4 -4
- package/lib/commonjs/specs/modules/NativeZixflowLocation.js.map +1 -0
- package/lib/commonjs/specs/modules/NativeZixflowLogging.js +19 -0
- package/lib/commonjs/specs/modules/NativeZixflowLogging.js.map +1 -0
- package/lib/commonjs/specs/modules/NativeZixflowMessagingInApp.js +16 -0
- package/lib/commonjs/specs/modules/NativeZixflowMessagingInApp.js.map +1 -0
- package/lib/commonjs/specs/modules/{NativeCustomerIOMessagingPush.js → NativeZixflowMessagingPush.js} +4 -4
- package/lib/commonjs/specs/modules/NativeZixflowMessagingPush.js.map +1 -0
- package/lib/commonjs/types/data-pipelines.js +23 -23
- package/lib/commonjs/types/data-pipelines.js.map +1 -1
- package/lib/commonjs/types/push.js +6 -6
- package/lib/commonjs/types/push.js.map +1 -1
- package/lib/commonjs/utils/native-bridge.js +1 -1
- package/lib/commonjs/utils/native-bridge.js.map +1 -1
- package/lib/commonjs/utils/param-validation.js +4 -4
- package/lib/commonjs/utils/param-validation.js.map +1 -1
- package/lib/commonjs/{customerio-cdp.js → zixflow-cdp.js} +19 -19
- package/lib/commonjs/zixflow-cdp.js.map +1 -0
- package/lib/commonjs/{customerio-inapp.js → zixflow-inapp.js} +8 -7
- package/lib/commonjs/zixflow-inapp.js.map +1 -0
- package/lib/commonjs/{customerio-location.js → zixflow-location.js} +10 -10
- package/lib/commonjs/zixflow-location.js.map +1 -0
- package/lib/commonjs/zixflow-params.js +2 -0
- package/lib/commonjs/zixflow-params.js.map +1 -0
- package/lib/commonjs/{customerio-push.js → zixflow-push.js} +11 -11
- package/lib/commonjs/zixflow-push.js.map +1 -0
- package/lib/commonjs/zixflow.js +19 -26
- package/lib/commonjs/zixflow.js.map +1 -1
- package/lib/module/index.js +3 -3
- package/lib/module/native-logger-listener.js +11 -11
- package/lib/module/native-logger-listener.js.map +1 -1
- package/lib/module/notification-inbox.js +4 -4
- package/lib/module/notification-inbox.js.map +1 -1
- package/lib/module/postInstall.js +1 -1
- package/lib/module/postInstall.js.map +1 -1
- package/lib/module/specs/modules/{NativeCustomerIO.js → NativeZixflow.js} +6 -6
- package/lib/module/specs/modules/NativeZixflow.js.map +1 -0
- package/lib/module/specs/modules/NativeZixflowLocation.js +13 -0
- package/lib/module/specs/modules/NativeZixflowLocation.js.map +1 -0
- package/lib/module/specs/modules/NativeZixflowLogging.js +18 -0
- package/lib/module/specs/modules/NativeZixflowLogging.js.map +1 -0
- package/lib/module/specs/modules/NativeZixflowMessagingInApp.js +15 -0
- package/lib/module/specs/modules/NativeZixflowMessagingInApp.js.map +1 -0
- package/lib/module/specs/modules/NativeZixflowMessagingPush.js +13 -0
- package/lib/module/specs/modules/NativeZixflowMessagingPush.js.map +1 -0
- package/lib/module/types/data-pipelines.js +22 -22
- package/lib/module/types/data-pipelines.js.map +1 -1
- package/lib/module/types/push.js +5 -5
- package/lib/module/types/push.js.map +1 -1
- package/lib/module/utils/native-bridge.js +1 -1
- package/lib/module/utils/native-bridge.js.map +1 -1
- package/lib/module/utils/param-validation.js +4 -4
- package/lib/module/utils/param-validation.js.map +1 -1
- package/lib/module/{customerio-cdp.js → zixflow-cdp.js} +16 -16
- package/lib/module/zixflow-cdp.js.map +1 -0
- package/lib/module/{customerio-inapp.js → zixflow-inapp.js} +6 -6
- package/lib/module/zixflow-inapp.js.map +1 -0
- package/lib/module/{customerio-location.js → zixflow-location.js} +6 -6
- package/lib/module/zixflow-location.js.map +1 -0
- package/lib/module/zixflow-params.js +2 -0
- package/lib/module/zixflow-params.js.map +1 -0
- package/lib/module/{customerio-push.js → zixflow-push.js} +10 -10
- package/lib/module/zixflow-push.js.map +1 -0
- package/lib/module/zixflow.js +5 -11
- package/lib/module/zixflow.js.map +1 -1
- package/lib/typescript/commonjs/index.d.ts +2 -2
- package/lib/typescript/commonjs/native-logger-listener.d.ts.map +1 -1
- package/lib/typescript/commonjs/notification-inbox.d.ts +1 -1
- package/lib/typescript/commonjs/specs/modules/{NativeCustomerIO.d.ts → NativeZixflow.d.ts} +5 -5
- package/lib/typescript/commonjs/specs/modules/NativeZixflow.d.ts.map +1 -0
- package/lib/typescript/commonjs/specs/modules/{NativeCustomerIOLocation.d.ts → NativeZixflowLocation.d.ts} +3 -3
- package/lib/typescript/commonjs/specs/modules/NativeZixflowLocation.d.ts.map +1 -0
- package/lib/typescript/commonjs/specs/modules/NativeZixflowLogging.d.ts +18 -0
- package/lib/typescript/commonjs/specs/modules/NativeZixflowLogging.d.ts.map +1 -0
- package/lib/typescript/commonjs/specs/modules/{NativeCustomerIOMessagingInApp.d.ts → NativeZixflowMessagingInApp.d.ts} +4 -4
- package/lib/typescript/commonjs/specs/modules/NativeZixflowMessagingInApp.d.ts.map +1 -0
- package/lib/typescript/{module/specs/modules/NativeCustomerIOMessagingPush.d.ts → commonjs/specs/modules/NativeZixflowMessagingPush.d.ts} +3 -3
- package/lib/typescript/commonjs/specs/modules/NativeZixflowMessagingPush.d.ts.map +1 -0
- package/lib/typescript/commonjs/types/data-pipelines.d.ts +14 -14
- package/lib/typescript/commonjs/types/data-pipelines.d.ts.map +1 -1
- package/lib/typescript/commonjs/types/internal.d.ts +2 -2
- package/lib/typescript/commonjs/types/push.d.ts +2 -2
- package/lib/typescript/commonjs/types/push.d.ts.map +1 -1
- package/lib/typescript/commonjs/utils/param-validation.d.ts +2 -2
- package/lib/typescript/commonjs/utils/param-validation.d.ts.map +1 -1
- package/lib/typescript/commonjs/{customerio-cdp.d.ts → zixflow-cdp.d.ts} +12 -12
- package/lib/typescript/commonjs/zixflow-cdp.d.ts.map +1 -0
- package/lib/typescript/{module/customerio-inapp.d.ts → commonjs/zixflow-inapp.d.ts} +4 -4
- package/lib/typescript/commonjs/zixflow-inapp.d.ts.map +1 -0
- package/lib/typescript/commonjs/{customerio-location.d.ts → zixflow-location.d.ts} +5 -5
- package/lib/typescript/commonjs/zixflow-location.d.ts.map +1 -0
- package/lib/typescript/commonjs/{cio-params.d.ts → zixflow-params.d.ts} +1 -1
- package/lib/typescript/commonjs/zixflow-params.d.ts.map +1 -0
- package/lib/typescript/{module/customerio-push.d.ts → commonjs/zixflow-push.d.ts} +11 -11
- package/lib/typescript/commonjs/zixflow-push.d.ts.map +1 -0
- package/lib/typescript/commonjs/zixflow.d.ts +5 -7
- package/lib/typescript/commonjs/zixflow.d.ts.map +1 -1
- package/lib/typescript/module/index.d.ts +2 -2
- package/lib/typescript/module/native-logger-listener.d.ts.map +1 -1
- package/lib/typescript/module/notification-inbox.d.ts +1 -1
- package/lib/typescript/module/specs/modules/{NativeCustomerIO.d.ts → NativeZixflow.d.ts} +5 -5
- package/lib/typescript/module/specs/modules/NativeZixflow.d.ts.map +1 -0
- package/lib/typescript/module/specs/modules/{NativeCustomerIOLocation.d.ts → NativeZixflowLocation.d.ts} +3 -3
- package/lib/typescript/module/specs/modules/NativeZixflowLocation.d.ts.map +1 -0
- package/lib/typescript/module/specs/modules/NativeZixflowLogging.d.ts +18 -0
- package/lib/typescript/module/specs/modules/NativeZixflowLogging.d.ts.map +1 -0
- package/lib/typescript/module/specs/modules/{NativeCustomerIOMessagingInApp.d.ts → NativeZixflowMessagingInApp.d.ts} +4 -4
- package/lib/typescript/module/specs/modules/NativeZixflowMessagingInApp.d.ts.map +1 -0
- package/lib/typescript/{commonjs/specs/modules/NativeCustomerIOMessagingPush.d.ts → module/specs/modules/NativeZixflowMessagingPush.d.ts} +3 -3
- package/lib/typescript/module/specs/modules/NativeZixflowMessagingPush.d.ts.map +1 -0
- package/lib/typescript/module/types/data-pipelines.d.ts +14 -14
- package/lib/typescript/module/types/data-pipelines.d.ts.map +1 -1
- package/lib/typescript/module/types/internal.d.ts +2 -2
- package/lib/typescript/module/types/push.d.ts +2 -2
- package/lib/typescript/module/types/push.d.ts.map +1 -1
- package/lib/typescript/module/utils/param-validation.d.ts +2 -2
- package/lib/typescript/module/utils/param-validation.d.ts.map +1 -1
- package/lib/typescript/module/{customerio-cdp.d.ts → zixflow-cdp.d.ts} +12 -12
- package/lib/typescript/module/zixflow-cdp.d.ts.map +1 -0
- package/lib/typescript/{commonjs/customerio-inapp.d.ts → module/zixflow-inapp.d.ts} +4 -4
- package/lib/typescript/module/zixflow-inapp.d.ts.map +1 -0
- package/lib/typescript/module/{customerio-location.d.ts → zixflow-location.d.ts} +5 -5
- package/lib/typescript/module/zixflow-location.d.ts.map +1 -0
- package/lib/typescript/module/{cio-params.d.ts → zixflow-params.d.ts} +1 -1
- package/lib/typescript/module/zixflow-params.d.ts.map +1 -0
- package/lib/typescript/{commonjs/customerio-push.d.ts → module/zixflow-push.d.ts} +11 -11
- package/lib/typescript/module/zixflow-push.d.ts.map +1 -0
- package/lib/typescript/module/zixflow.d.ts +5 -7
- package/lib/typescript/module/zixflow.d.ts.map +1 -1
- package/package.json +11 -12
- package/src/index.ts +3 -3
- package/src/native-logger-listener.ts +14 -14
- package/src/notification-inbox.ts +5 -5
- package/src/postInstall.js +1 -1
- package/src/specs/modules/{NativeCustomerIO.ts → NativeZixflow.ts} +5 -5
- package/src/specs/modules/{NativeCustomerIOLocation.ts → NativeZixflowLocation.ts} +3 -3
- package/src/specs/modules/NativeZixflowLogging.ts +22 -0
- package/src/specs/modules/{NativeCustomerIOMessagingInApp.ts → NativeZixflowMessagingInApp.ts} +4 -4
- package/src/specs/modules/{NativeCustomerIOMessagingPush.ts → NativeZixflowMessagingPush.ts} +3 -3
- package/src/types/data-pipelines.ts +14 -14
- package/src/types/internal.ts +2 -2
- package/src/types/push.ts +2 -2
- package/src/utils/native-bridge.ts +1 -1
- package/src/utils/param-validation.ts +8 -8
- package/src/{customerio-cdp.ts → zixflow-cdp.ts} +17 -17
- package/src/{customerio-inapp.ts → zixflow-inapp.ts} +6 -6
- package/src/{customerio-location.ts → zixflow-location.ts} +6 -6
- package/src/{customerio-push.ts → zixflow-push.ts} +19 -17
- package/src/zixflow.ts +5 -15
- package/zixflow-reactnative.podspec +16 -22
- package/customerio-reactnative.podspec +0 -60
- package/lib/commonjs/cio-params.js +0 -2
- package/lib/commonjs/cio-params.js.map +0 -1
- package/lib/commonjs/customerio-cdp.js.map +0 -1
- package/lib/commonjs/customerio-inapp.js.map +0 -1
- package/lib/commonjs/customerio-location.js.map +0 -1
- package/lib/commonjs/customerio-push.js.map +0 -1
- package/lib/commonjs/specs/modules/NativeCustomerIO.js.map +0 -1
- package/lib/commonjs/specs/modules/NativeCustomerIOLocation.js.map +0 -1
- package/lib/commonjs/specs/modules/NativeCustomerIOLogging.js +0 -19
- package/lib/commonjs/specs/modules/NativeCustomerIOLogging.js.map +0 -1
- package/lib/commonjs/specs/modules/NativeCustomerIOMessagingInApp.js +0 -16
- package/lib/commonjs/specs/modules/NativeCustomerIOMessagingInApp.js.map +0 -1
- package/lib/commonjs/specs/modules/NativeCustomerIOMessagingPush.js.map +0 -1
- package/lib/module/cio-params.js +0 -2
- package/lib/module/cio-params.js.map +0 -1
- package/lib/module/customerio-cdp.js.map +0 -1
- package/lib/module/customerio-inapp.js.map +0 -1
- package/lib/module/customerio-location.js.map +0 -1
- package/lib/module/customerio-push.js.map +0 -1
- package/lib/module/specs/modules/NativeCustomerIO.js.map +0 -1
- package/lib/module/specs/modules/NativeCustomerIOLocation.js +0 -13
- package/lib/module/specs/modules/NativeCustomerIOLocation.js.map +0 -1
- package/lib/module/specs/modules/NativeCustomerIOLogging.js +0 -18
- package/lib/module/specs/modules/NativeCustomerIOLogging.js.map +0 -1
- package/lib/module/specs/modules/NativeCustomerIOMessagingInApp.js +0 -15
- package/lib/module/specs/modules/NativeCustomerIOMessagingInApp.js.map +0 -1
- package/lib/module/specs/modules/NativeCustomerIOMessagingPush.js +0 -13
- package/lib/module/specs/modules/NativeCustomerIOMessagingPush.js.map +0 -1
- package/lib/typescript/commonjs/cio-params.d.ts.map +0 -1
- package/lib/typescript/commonjs/customerio-cdp.d.ts.map +0 -1
- package/lib/typescript/commonjs/customerio-inapp.d.ts.map +0 -1
- package/lib/typescript/commonjs/customerio-location.d.ts.map +0 -1
- package/lib/typescript/commonjs/customerio-push.d.ts.map +0 -1
- package/lib/typescript/commonjs/specs/modules/NativeCustomerIO.d.ts.map +0 -1
- package/lib/typescript/commonjs/specs/modules/NativeCustomerIOLocation.d.ts.map +0 -1
- package/lib/typescript/commonjs/specs/modules/NativeCustomerIOLogging.d.ts +0 -18
- package/lib/typescript/commonjs/specs/modules/NativeCustomerIOLogging.d.ts.map +0 -1
- package/lib/typescript/commonjs/specs/modules/NativeCustomerIOMessagingInApp.d.ts.map +0 -1
- package/lib/typescript/commonjs/specs/modules/NativeCustomerIOMessagingPush.d.ts.map +0 -1
- package/lib/typescript/module/cio-params.d.ts.map +0 -1
- package/lib/typescript/module/customerio-cdp.d.ts.map +0 -1
- package/lib/typescript/module/customerio-inapp.d.ts.map +0 -1
- package/lib/typescript/module/customerio-location.d.ts.map +0 -1
- package/lib/typescript/module/customerio-push.d.ts.map +0 -1
- package/lib/typescript/module/specs/modules/NativeCustomerIO.d.ts.map +0 -1
- package/lib/typescript/module/specs/modules/NativeCustomerIOLocation.d.ts.map +0 -1
- package/lib/typescript/module/specs/modules/NativeCustomerIOLogging.d.ts +0 -18
- package/lib/typescript/module/specs/modules/NativeCustomerIOLogging.d.ts.map +0 -1
- package/lib/typescript/module/specs/modules/NativeCustomerIOMessagingInApp.d.ts.map +0 -1
- package/lib/typescript/module/specs/modules/NativeCustomerIOMessagingPush.d.ts.map +0 -1
- package/src/specs/modules/NativeCustomerIOLogging.ts +0 -24
- /package/android/{cio-core.gradle → zixflow-core.gradle} +0 -0
- /package/src/{cio-params.ts → zixflow-params.ts} +0 -0
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
import
|
|
4
|
-
import {
|
|
3
|
+
import NativeZixflowLogging from "./specs/modules/NativeZixflowLogging.js";
|
|
4
|
+
import { ZixflowLogLevel } from "./types/index.js";
|
|
5
5
|
import { callNativeModule, ensureNativeModule } from "./utils/native-bridge.js";
|
|
6
6
|
|
|
7
|
-
// Reference to the native
|
|
8
|
-
const nativeModule = ensureNativeModule(
|
|
7
|
+
// Reference to the native Zixflow logging module for SDK operations
|
|
8
|
+
const nativeModule = ensureNativeModule(NativeZixflowLogging);
|
|
9
9
|
|
|
10
10
|
// Wrapper function that ensures SDK is initialized before calling native methods
|
|
11
11
|
const withNativeModule = fn => {
|
|
@@ -15,8 +15,8 @@ const withNativeModule = fn => {
|
|
|
15
15
|
/* @internal */
|
|
16
16
|
export class NativeLoggerListener {
|
|
17
17
|
static isInitialized = false;
|
|
18
|
-
// Prefix for all
|
|
19
|
-
static loggerPrefix = '[
|
|
18
|
+
// Prefix for all Zixflow log messages
|
|
19
|
+
static loggerPrefix = '[Zixflow] ';
|
|
20
20
|
static async initialize() {
|
|
21
21
|
// Prevent multiple registrations of the same log listener
|
|
22
22
|
if (this.isInitialized) {
|
|
@@ -29,13 +29,13 @@ export class NativeLoggerListener {
|
|
|
29
29
|
// the JavaScript and native ends.
|
|
30
30
|
const logEvent = async event => {
|
|
31
31
|
switch (event.logLevel) {
|
|
32
|
-
case
|
|
32
|
+
case ZixflowLogLevel.Debug:
|
|
33
33
|
console.debug(this.loggerPrefix + event.message);
|
|
34
34
|
break;
|
|
35
|
-
case
|
|
35
|
+
case ZixflowLogLevel.Info:
|
|
36
36
|
console.info(this.loggerPrefix + event.message);
|
|
37
37
|
break;
|
|
38
|
-
case
|
|
38
|
+
case ZixflowLogLevel.Error:
|
|
39
39
|
console.error(this.loggerPrefix + event.message);
|
|
40
40
|
break;
|
|
41
41
|
default:
|
|
@@ -52,7 +52,7 @@ export class NativeLoggerListener {
|
|
|
52
52
|
// Register TurboModule event listener and return subscription.
|
|
53
53
|
// This method is generated by codegen in the native modules.
|
|
54
54
|
// Wrapped in try-catch due to previous reports of crashes on certain Android architectures.
|
|
55
|
-
native.
|
|
55
|
+
native.onZixflowLogEvent(logHandler);
|
|
56
56
|
} catch (error) {
|
|
57
57
|
NativeLoggerListener.warn('Failed to attach log listener:', error);
|
|
58
58
|
}
|
|
@@ -60,7 +60,7 @@ export class NativeLoggerListener {
|
|
|
60
60
|
this.isInitialized = true;
|
|
61
61
|
}
|
|
62
62
|
|
|
63
|
-
// Logs warning messages in development mode only, with
|
|
63
|
+
// Logs warning messages in development mode only, with Zixflow prefix
|
|
64
64
|
static warn(message, error) {
|
|
65
65
|
if (__DEV__) {
|
|
66
66
|
console.warn(this.loggerPrefix + message, error);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["
|
|
1
|
+
{"version":3,"names":["NativeZixflowLogging","ZixflowLogLevel","callNativeModule","ensureNativeModule","nativeModule","withNativeModule","fn","NativeLoggerListener","isInitialized","loggerPrefix","initialize","Promise","resolve","logEvent","event","logLevel","Debug","console","debug","message","Info","info","Error","error","log","logHandler","data","native","onZixflowLogEvent","warn","__DEV__","initNativeLogger"],"sourceRoot":"../../src","sources":["native-logger-listener.ts"],"mappings":";;AAAA,OAAOA,oBAAoB,MAAM,yCAAsC;AACvE,SAASC,eAAe,QAAQ,kBAAS;AACzC,SAASC,gBAAgB,EAAEC,kBAAkB,QAAQ,0BAAuB;;AAE5E;AACA,MAAMC,YAAY,GAAGD,kBAAkB,CAACH,oBAAoB,CAAC;;AAE7D;AACA,MAAMK,gBAAgB,GACpBC,EAA8C,IACxC;EACN,OAAOJ,gBAAgB,CAACE,YAAY,EAAEE,EAAE,CAAC;AAC3C,CAAC;;AAED;AACA,OAAO,MAAMC,oBAAoB,CAAC;EAChC,OAAeC,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,CAAC,IAAI,CAACpB,YAAY,GAAGU,OAAO,EAAEI,KAAK,CAAC;IAClD;EACF;;EAEA;EACA,OAAOQ,gBAAgBA,CAAA,EAAG;IACxB,IAAI;MACFxB,oBAAoB,CAACG,UAAU,CAAC,CAAC;IACnC,CAAC,CAAC,OAAOa,KAAK,EAAE;MACdhB,oBAAoB,CAACsB,IAAI,CAAC,qCAAqC,EAAEN,KAAK,CAAC;IACzE;EACF;AACF","ignoreList":[]}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
3
|
import { NativeLoggerListener } from "./native-logger-listener.js";
|
|
4
|
-
import
|
|
4
|
+
import NativeZixflowMessagingInApp from "./specs/modules/NativeZixflowMessagingInApp.js";
|
|
5
5
|
import { callNativeModule, ensureNativeModule } from "./utils/native-bridge.js";
|
|
6
6
|
|
|
7
|
-
// Reference to the native
|
|
8
|
-
const nativeModule = ensureNativeModule(
|
|
7
|
+
// Reference to the native Zixflow In-App Messaging module
|
|
8
|
+
const nativeModule = ensureNativeModule(NativeZixflowMessagingInApp);
|
|
9
9
|
|
|
10
10
|
// Wrapper function that ensures SDK is initialized before calling native methods
|
|
11
11
|
const withNativeModule = fn => {
|
|
@@ -20,7 +20,7 @@ const withNativeModule = fn => {
|
|
|
20
20
|
*/
|
|
21
21
|
|
|
22
22
|
/**
|
|
23
|
-
* Native inbox methods from CodegenSpec that should be excluded from
|
|
23
|
+
* Native inbox methods from CodegenSpec that should be excluded from ZixflowInAppMessaging.
|
|
24
24
|
* Includes both public methods (in NotificationInboxPublicSpec) and internal methods.
|
|
25
25
|
*
|
|
26
26
|
* @internal
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["NativeLoggerListener","
|
|
1
|
+
{"version":3,"names":["NativeLoggerListener","NativeZixflowMessagingInApp","callNativeModule","ensureNativeModule","nativeModule","withNativeModule","fn","parseInboxMessage","raw","queueId","deliveryId","undefined","expiry","sentAt","topics","type","opened","priority","properties","NotificationInbox","getMessages","topic","native","rawMessages","map","subscribeToMessages","listener","emitter","data","messages","topicLower","toLowerCase","filter","msg","some","t","onMessagesChanged","setupInboxListener","subscribeToMessagesChanged","error","warn","remove","eventType","key","subscriber","markMessageOpened","message","markMessageUnopened","markMessageDeleted","trackMessageClicked","actionName"],"sourceRoot":"../../src","sources":["notification-inbox.ts"],"mappings":";;AACA,SAASA,oBAAoB,QAAQ,6BAA0B;AAE/D,OAAOC,2BAA2B,MAAM,gDAA6C;AAErF,SAASC,gBAAgB,EAAEC,kBAAkB,QAAQ,0BAAuB;;AAE5E;AACA,MAAMC,YAAY,GAAGD,kBAAkB,CAACF,2BAA2B,CAAC;;AAEpE;AACA,MAAMI,gBAAgB,GAAOC,EAA8B,IAAQ;EACjE,OAAOJ,gBAAgB,CAACE,YAAY,EAAEE,EAAE,CAAC;AAC3C,CAAC;;AAED;AACA;AACA;AACA;AACA;AACA;;AAaA;AACA;AACA;AACA;AACA;AACA;;AAMA;AACA;AACA;AACA;AACA,SAASC,iBAAiBA,CAACC,GAAQ,EAAgB;EACjD,OAAO;IACLC,OAAO,EAAED,GAAG,CAACC,OAAO;IACpBC,UAAU,EAAEF,GAAG,CAACE,UAAU,IAAIC,SAAS;IACvCC,MAAM,EAAEJ,GAAG,CAACI,MAAM,IAAID,SAAS;IAC/BE,MAAM,EAAEL,GAAG,CAACK,MAAM;IAClBC,MAAM,EAAEN,GAAG,CAACM,MAAM,IAAI,EAAE;IACxBC,IAAI,EAAEP,GAAG,CAACO,IAAI;IACdC,MAAM,EAAER,GAAG,CAACQ,MAAM;IAClBC,QAAQ,EAAET,GAAG,CAACS,QAAQ,IAAIN,SAAS;IACnCO,UAAU,EAAEV,GAAG,CAACU,UAAU,IAAI,CAAC;EACjC,CAAC;AACH;;AAEA;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMC,iBAAiB,CAAwC;EACpE;AACF;AACA;EACE,MAAMC,WAAWA,CAACC,KAAc,EAA2B;IACzD,OAAOhB,gB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MAAM,CAACuB,iBAAiB,CAACC,OAAO,CAAC,CAAC;EACjE;;EAEA;AACF;AACA;EACEC,mBAAmBA,CAACD,OAAqB,EAAE;IACzCzC,gBAAgB,CAAEiB,MAAM,IAAKA,MAAM,CAACyB,mBAAmB,CAACD,OAAO,CAAC,CAAC;EACnE;;EAEA;AACF;AACA;EACEE,kBAAkBA,CAACF,OAAqB,EAAE;IACxCzC,gBAAgB,CAAEiB,MAAM,IAAKA,MAAM,CAAC0B,kBAAkB,CAACF,OAAO,CAAC,CAAC;EAClE;;EAEA;AACF;AACA;EACEG,mBAAmBA,CAACH,OAAqB,EAAEI,UAAmB,EAAE;IAC9D7C,gBAAgB,CAAEiB,MAAM,IACtBA,MAAM,CAAC2B,mBAAmB,CAACH,OAAO,EAAEI,UAAU,CAChD,CAAC;EACH;AACF","ignoreList":[]}
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
If it succeeds, we use Expo as the user agent instead of React Native.
|
|
8
8
|
*/
|
|
9
9
|
try {
|
|
10
|
-
const ph = require('
|
|
10
|
+
const ph = require('zixflow-expo-plugin/postinstall');
|
|
11
11
|
ph.runPostInstall();
|
|
12
12
|
} catch {}
|
|
13
13
|
//# sourceMappingURL=postInstall.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["ph","require","runPostInstall"],"sourceRoot":"../../src","sources":["postInstall.js"],"mappings":";;AAAA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;EACF,MAAMA,EAAE,GAAGC,OAAO,CAAC,
|
|
1
|
+
{"version":3,"names":["ph","require","runPostInstall"],"sourceRoot":"../../src","sources":["postInstall.js"],"mappings":";;AAAA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;EACF,MAAMA,EAAE,GAAGC,OAAO,CAAC,iCAAiC,CAAC;EACrDD,EAAE,CAACE,cAAc,CAAC,CAAC;AACrB,CAAC,CAAC,MAAM,CAAC","ignoreList":[]}
|
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
import { TurboModuleRegistry } from 'react-native';
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
|
-
* Native module specification for
|
|
6
|
+
* Native module specification for Zixflow React Native SDK
|
|
7
7
|
*
|
|
8
|
-
* This module defines the TurboModule interface for
|
|
8
|
+
* This module defines the TurboModule interface for Zixflow SDK native bridge.
|
|
9
9
|
* Types use basic primitives for React Native Codegen compatibility, while the public
|
|
10
10
|
* API layer provides more specific TypeScript types for better developer experience.
|
|
11
11
|
*
|
|
@@ -22,7 +22,7 @@ import { TurboModuleRegistry } from 'react-native';
|
|
|
22
22
|
*
|
|
23
23
|
* Used for all complex data structures passed to native methods to ensure
|
|
24
24
|
* React Native Codegen compatibility. The public API layer converts these
|
|
25
|
-
* to proper TypeScript types (CustomAttributes,
|
|
25
|
+
* to proper TypeScript types (CustomAttributes, ZixflowConfig, etc.) for
|
|
26
26
|
* better type safety and developer experience.
|
|
27
27
|
*
|
|
28
28
|
* @internal - Not exported to avoid conflicts with public API types
|
|
@@ -33,9 +33,9 @@ import { TurboModuleRegistry } from 'react-native';
|
|
|
33
33
|
// =============================================================================
|
|
34
34
|
|
|
35
35
|
/**
|
|
36
|
-
* TurboModule specification for
|
|
36
|
+
* TurboModule specification for Zixflow SDK native bridge methods.
|
|
37
37
|
* Uses generic Object types for React Native Codegen compatibility.
|
|
38
38
|
*/
|
|
39
39
|
|
|
40
|
-
export default TurboModuleRegistry.getEnforcing('
|
|
41
|
-
//# sourceMappingURL=
|
|
40
|
+
export default TurboModuleRegistry.getEnforcing('NativeZixflow');
|
|
41
|
+
//# sourceMappingURL=NativeZixflow.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["TurboModuleRegistry","getEnforcing"],"sourceRoot":"../../../../src","sources":["specs/modules/NativeZixflow.ts"],"mappings":";;AAAA,SAASA,mBAAmB,QAA0B,cAAc;;AAGpE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAGA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAiBA,eAAeA,mBAAmB,CAACC,YAAY,CAAO,eAAe,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { TurboModuleRegistry } from 'react-native';
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* Native module specification for Zixflow Location React Native SDK
|
|
7
|
+
*
|
|
8
|
+
* @see NativeZixflow.ts for detailed documentation on TurboModule patterns,
|
|
9
|
+
* Codegen compatibility, and type safety approach.
|
|
10
|
+
*/
|
|
11
|
+
|
|
12
|
+
export default TurboModuleRegistry.get('NativeZixflowLocation');
|
|
13
|
+
//# sourceMappingURL=NativeZixflowLocation.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["TurboModuleRegistry","get"],"sourceRoot":"../../../../src","sources":["specs/modules/NativeZixflowLocation.ts"],"mappings":";;AAAA,SAASA,mBAAmB,QAA0B,cAAc;;AAEpE;AACA;AACA;AACA;AACA;AACA;;AAOA,eAAeA,mBAAmB,CAACC,GAAG,CAAO,uBAAuB,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { TurboModuleRegistry } from 'react-native';
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* Native module specification for Zixflow Logging React Native SDK
|
|
7
|
+
*
|
|
8
|
+
* This module defines the TurboModule interface for Zixflow logging bridge.
|
|
9
|
+
* Used internally for printing logs to React Native environment instead of native.
|
|
10
|
+
*
|
|
11
|
+
* @see NativeZixflow.ts for detailed documentation on TurboModule patterns,
|
|
12
|
+
* Codegen compatibility, and type safety approach.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
/** TurboModule interface for Zixflow logging native operations */
|
|
16
|
+
|
|
17
|
+
export default TurboModuleRegistry.getEnforcing('NativeZixflowLogging');
|
|
18
|
+
//# sourceMappingURL=NativeZixflowLogging.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["TurboModuleRegistry","getEnforcing"],"sourceRoot":"../../../../src","sources":["specs/modules/NativeZixflowLogging.ts"],"mappings":";;AAAA,SAASA,mBAAmB,QAA0B,cAAc;;AAMpE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAKA,eAAeA,mBAAmB,CAACC,YAAY,CAAO,sBAAsB,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { TurboModuleRegistry } from 'react-native';
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* Native module specification for Zixflow In-App Messaging React Native SDK
|
|
7
|
+
*
|
|
8
|
+
* @see NativeZixflow.ts for detailed documentation on TurboModule patterns,
|
|
9
|
+
* Codegen compatibility, and type safety approach.
|
|
10
|
+
*/
|
|
11
|
+
|
|
12
|
+
/** TurboModule interface for Zixflow In-App Messaging native operations */
|
|
13
|
+
|
|
14
|
+
export default TurboModuleRegistry.getEnforcing('NativeZixflowMessagingInApp');
|
|
15
|
+
//# sourceMappingURL=NativeZixflowMessagingInApp.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["TurboModuleRegistry","getEnforcing"],"sourceRoot":"../../../../src","sources":["specs/modules/NativeZixflowMessagingInApp.ts"],"mappings":";;AAAA,SAASA,mBAAmB,QAA0B,cAAc;;AAMpE;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAcA,eAAeA,mBAAmB,CAACC,YAAY,CAC7C,6BACF,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { TurboModuleRegistry } from 'react-native';
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* Native module specification for Zixflow Push Messaging React Native SDK
|
|
7
|
+
*
|
|
8
|
+
* @see NativeZixflow.ts for detailed documentation on TurboModule patterns,
|
|
9
|
+
* Codegen compatibility, and type safety approach.
|
|
10
|
+
*/
|
|
11
|
+
|
|
12
|
+
export default TurboModuleRegistry.getEnforcing('NativeZixflowMessagingPush');
|
|
13
|
+
//# sourceMappingURL=NativeZixflowMessagingPush.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["TurboModuleRegistry","getEnforcing"],"sourceRoot":"../../../../src","sources":["specs/modules/NativeZixflowMessagingPush.ts"],"mappings":";;AAAA,SAASA,mBAAmB,QAA0B,cAAc;;AAGpE;AACA;AACA;AACA;AACA;AACA;;AAgBA,eAAeA,mBAAmB,CAACC,YAAY,CAC7C,4BACF,CAAC","ignoreList":[]}
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
/**
|
|
4
4
|
* Key-value pairs for custom user attributes and event properties.
|
|
5
5
|
*
|
|
6
|
-
* Provides a type-safe interface for passing custom data to
|
|
6
|
+
* Provides a type-safe interface for passing custom data to Zixflow.
|
|
7
7
|
* While the native bridge uses generic Object types for Codegen compatibility,
|
|
8
8
|
* this type gives developers better TypeScript intellisense and validation.
|
|
9
9
|
*
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
*/
|
|
21
21
|
|
|
22
22
|
/**
|
|
23
|
-
* Parameters for identifying a user in
|
|
23
|
+
* Parameters for identifying a user in Zixflow.
|
|
24
24
|
*
|
|
25
25
|
* @param userId - Unique identifier for the user (email, username, etc.)
|
|
26
26
|
* @param traits - Additional user attributes and properties
|
|
@@ -29,9 +29,9 @@
|
|
|
29
29
|
*/
|
|
30
30
|
|
|
31
31
|
/**
|
|
32
|
-
* Configuration options for initializing the
|
|
32
|
+
* Configuration options for initializing the Zixflow SDK.
|
|
33
33
|
*
|
|
34
|
-
* @param cdpApiKey - Customer Data Platform API key from
|
|
34
|
+
* @param cdpApiKey - Customer Data Platform API key from Zixflow dashboard
|
|
35
35
|
* @param migrationSiteId - Legacy site ID for migrating from tracking API
|
|
36
36
|
* @param region - Data center region (US or EU)
|
|
37
37
|
* @param logLevel - SDK logging verbosity level
|
|
@@ -49,33 +49,33 @@
|
|
|
49
49
|
*/
|
|
50
50
|
|
|
51
51
|
/**
|
|
52
|
-
* Log levels for
|
|
52
|
+
* Log levels for Zixflow SDK debugging and monitoring.
|
|
53
53
|
*
|
|
54
54
|
* Controls the verbosity of SDK logging output for debugging purposes.
|
|
55
55
|
*
|
|
56
56
|
* @public
|
|
57
57
|
*/
|
|
58
|
-
export let
|
|
58
|
+
export let ZixflowLogLevel = /*#__PURE__*/function (ZixflowLogLevel) {
|
|
59
59
|
/** No logging output */
|
|
60
|
-
|
|
60
|
+
ZixflowLogLevel["None"] = "none";
|
|
61
61
|
/** Only error messages */
|
|
62
|
-
|
|
62
|
+
ZixflowLogLevel["Error"] = "error";
|
|
63
63
|
/** Error and informational messages */
|
|
64
|
-
|
|
64
|
+
ZixflowLogLevel["Info"] = "info";
|
|
65
65
|
/** All messages including debug information */
|
|
66
|
-
|
|
67
|
-
return
|
|
66
|
+
ZixflowLogLevel["Debug"] = "debug";
|
|
67
|
+
return ZixflowLogLevel;
|
|
68
68
|
}({});
|
|
69
69
|
|
|
70
70
|
/**
|
|
71
|
-
* Data center regions for
|
|
71
|
+
* Data center regions for Zixflow API endpoints.
|
|
72
72
|
*
|
|
73
73
|
* @public
|
|
74
74
|
*/
|
|
75
|
-
export let
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
return
|
|
75
|
+
export let ZixflowRegion = /*#__PURE__*/function (ZixflowRegion) {
|
|
76
|
+
ZixflowRegion["US"] = "US";
|
|
77
|
+
ZixflowRegion["EU"] = "EU";
|
|
78
|
+
return ZixflowRegion;
|
|
79
79
|
}({});
|
|
80
80
|
|
|
81
81
|
/**
|
|
@@ -95,18 +95,18 @@ export let ScreenView = /*#__PURE__*/function (ScreenView) {
|
|
|
95
95
|
}({});
|
|
96
96
|
|
|
97
97
|
/**
|
|
98
|
-
* Location tracking mode for the
|
|
98
|
+
* Location tracking mode for the Zixflow Location module.
|
|
99
99
|
*
|
|
100
100
|
* @public
|
|
101
101
|
*/
|
|
102
|
-
export let
|
|
102
|
+
export let ZixflowLocationTrackingMode = /*#__PURE__*/function (ZixflowLocationTrackingMode) {
|
|
103
103
|
/** Location tracking is disabled. All location operations no-op. */
|
|
104
|
-
|
|
104
|
+
ZixflowLocationTrackingMode["Off"] = "OFF";
|
|
105
105
|
/** Host app controls when location is captured (default when location config is provided). */
|
|
106
|
-
|
|
106
|
+
ZixflowLocationTrackingMode["Manual"] = "MANUAL";
|
|
107
107
|
/** SDK auto-captures location once per app launch when the app becomes active. */
|
|
108
|
-
|
|
109
|
-
return
|
|
108
|
+
ZixflowLocationTrackingMode["OnAppStart"] = "ON_APP_START";
|
|
109
|
+
return ZixflowLocationTrackingMode;
|
|
110
110
|
}({});
|
|
111
111
|
|
|
112
112
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["
|
|
1
|
+
{"version":3,"names":["ZixflowLogLevel","ZixflowRegion","ScreenView","ZixflowLocationTrackingMode","MetricEvent"],"sourceRoot":"../../../src","sources":["types/data-pipelines.ts"],"mappings":";;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAGA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAMA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AA2BA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,WAAYA,eAAe,0BAAfA,eAAe;EACzB;EADUA,eAAe;EAGzB;EAHUA,eAAe;EAKzB;EALUA,eAAe;EAOzB;EAPUA,eAAe;EAAA,OAAfA,eAAe;AAAA;;AAW3B;AACA;AACA;AACA;AACA;AACA,WAAYC,aAAa,0BAAbA,aAAa;EAAbA,aAAa;EAAbA,aAAa;EAAA,OAAbA,aAAa;AAAA;;AAKzB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,WAAYC,UAAU,0BAAVA,UAAU;EACpB;EADUA,UAAU;EAGpB;EAHUA,UAAU;EAAA,OAAVA,UAAU;AAAA;;AAOtB;AACA;AACA;AACA;AACA;AACA,WAAYC,2BAA2B,0BAA3BA,2BAA2B;EACrC;EADUA,2BAA2B;EAGrC;EAHUA,2BAA2B;EAKrC;EALUA,2BAA2B;EAAA,OAA3BA,2BAA2B;AAAA;;AASvC;AACA;AACA;AACA;AACA;AACA,WAAYC,WAAW,0BAAXA,WAAW;EACrB;EADUA,WAAW;EAGrB;EAHUA,WAAW;EAKrB;EALUA,WAAW;EAAA,OAAXA,WAAW;AAAA","ignoreList":[]}
|
package/lib/module/types/push.js
CHANGED
|
@@ -35,13 +35,13 @@ export let PushClickBehaviorAndroid = /*#__PURE__*/function (PushClickBehaviorAn
|
|
|
35
35
|
*
|
|
36
36
|
* @public
|
|
37
37
|
*/
|
|
38
|
-
export let
|
|
38
|
+
export let ZixflowPushPermissionStatus = /*#__PURE__*/function (ZixflowPushPermissionStatus) {
|
|
39
39
|
/** User has granted push notification permissions */
|
|
40
|
-
|
|
40
|
+
ZixflowPushPermissionStatus["Granted"] = "GRANTED";
|
|
41
41
|
/** User has denied push notification permissions */
|
|
42
|
-
|
|
42
|
+
ZixflowPushPermissionStatus["Denied"] = "DENIED";
|
|
43
43
|
/** User may not yet have been asked for permissions and permission status is unknown */
|
|
44
|
-
|
|
45
|
-
return
|
|
44
|
+
ZixflowPushPermissionStatus["NotDetermined"] = "NOTDETERMINED";
|
|
45
|
+
return ZixflowPushPermissionStatus;
|
|
46
46
|
}({});
|
|
47
47
|
//# sourceMappingURL=push.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["PushClickBehaviorAndroid","
|
|
1
|
+
{"version":3,"names":["PushClickBehaviorAndroid","ZixflowPushPermissionStatus"],"sourceRoot":"../../../src","sources":["types/push.ts"],"mappings":";;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,WAAYA,wBAAwB,0BAAxBA,wBAAwB;EAClC;EADUA,wBAAwB;EAGlC;EAHUA,wBAAwB;EAKlC;EALUA,wBAAwB;EAAA,OAAxBA,wBAAwB;AAAA;;AASpC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAUA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,WAAYC,2BAA2B,0BAA3BA,2BAA2B;EACrC;EADUA,2BAA2B;EAGrC;EAHUA,2BAA2B;EAKrC;EALUA,2BAA2B;EAAA,OAA3BA,2BAA2B;AAAA","ignoreList":[]}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
3
|
import { Platform } from 'react-native';
|
|
4
|
-
const LINKING_ERROR = `The package '
|
|
4
|
+
const LINKING_ERROR = `The package 'zixflow-reactnative' doesn't seem to be linked. Make sure: \n\n` + Platform.select({
|
|
5
5
|
ios: "- You have run 'pod install'\n",
|
|
6
6
|
default: ''
|
|
7
7
|
}) + '- You rebuilt the app after installing the package\n' + '- You are not using Expo managed workflow\n';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["Platform","LINKING_ERROR","select","ios","default","ensureNativeModule","nativeModule","Error","callNativeModule","fn"],"sourceRoot":"../../../src","sources":["utils/native-bridge.ts"],"mappings":";;AAAA,SAASA,QAAQ,QAAQ,cAAc;AAEvC,MAAMC,aAAa,GACjB,
|
|
1
|
+
{"version":3,"names":["Platform","LINKING_ERROR","select","ios","default","ensureNativeModule","nativeModule","Error","callNativeModule","fn"],"sourceRoot":"../../../src","sources":["utils/native-bridge.ts"],"mappings":";;AAAA,SAASA,QAAQ,QAAQ,cAAc;AAEvC,MAAMC,aAAa,GACjB,8EAA8E,GAC9ED,QAAQ,CAACE,MAAM,CAAC;EAAEC,GAAG,EAAE,gCAAgC;EAAEC,OAAO,EAAE;AAAG,CAAC,CAAC,GACvE,sDAAsD,GACtD,6CAA6C;;AAE/C;AACA;AACA;AACA,OAAO,SAASC,kBAAkBA,CAChCC,YAAiC,EACnB;EACd,IAAI,CAACA,YAAY,EAAE;IACjB,MAAM,IAAIC,KAAK,CAACN,aAAa,CAAC;EAChC;EAEA,OAAOK,YAAY;AACrB;;AAEA;AACA;AACA;AACA,OAAO,MAAME,gBAAgB,GAAGA,CAC9BF,YAAkB,EAClBG,EAA4B,KACjB;EACX,OAAOA,EAAE,CAACH,YAAY,CAAC;AACzB,CAAC","ignoreList":[]}
|
|
@@ -24,7 +24,7 @@ function isUndefined(value) {
|
|
|
24
24
|
*/
|
|
25
25
|
function failIf(condition, message) {
|
|
26
26
|
if (__DEV__ && condition) {
|
|
27
|
-
throw new Error(`[
|
|
27
|
+
throw new Error(`[Zixflow] ${message()}`);
|
|
28
28
|
}
|
|
29
29
|
}
|
|
30
30
|
|
|
@@ -100,14 +100,14 @@ function validateAttributes(value, fieldName, options = {}) {
|
|
|
100
100
|
}
|
|
101
101
|
|
|
102
102
|
/**
|
|
103
|
-
* Validates that the given value is a valid
|
|
103
|
+
* Validates that the given value is a valid ZixflowConfig object.
|
|
104
104
|
* Throws if required fields are missing or incorrectly typed.
|
|
105
105
|
*/
|
|
106
106
|
function validateConfig(value) {
|
|
107
107
|
const fieldName = 'config';
|
|
108
108
|
const usage = 'SDK';
|
|
109
109
|
validateRecord(value, fieldName, {
|
|
110
|
-
expectedType: '
|
|
110
|
+
expectedType: 'ZixflowConfig',
|
|
111
111
|
usage: usage
|
|
112
112
|
});
|
|
113
113
|
const obj = value;
|
|
@@ -117,7 +117,7 @@ function validateConfig(value) {
|
|
|
117
117
|
});
|
|
118
118
|
}
|
|
119
119
|
|
|
120
|
-
// For type safety, we define a ConfigValidator type that asserts the value is a
|
|
120
|
+
// For type safety, we define a ConfigValidator type that asserts the value is a ZixflowConfig
|
|
121
121
|
// This allows us to use it in the assert object without needing to redefine the function signature
|
|
122
122
|
|
|
123
123
|
export const assert = {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["buildErrorMessage","usage","fieldName","error","prefix","isUndefined","value","undefined","failIf","condition","message","__DEV__","Error","failIfUndefined","validateString","options","allowEmpty","optional","typedValue","trim","validateRecord","expectedType","typeName","Array","isArray","validateAttributes","exists","attributes","Map","Object","fromEntries","validateConfig","obj","cdpApiKey","assert","string","record","config","validate"],"sourceRoot":"../../../src","sources":["utils/param-validation.ts"],"mappings":";;AAAA;AACA;;AAIA;AACA;AACA;AACA,SAASA,iBAAiBA,CACxBC,KAAyB,EACzBC,SAAiB,EACjBC,KAAa,EACL;EACR,MAAMC,MAAM,GAAGH,KAAK,GAAG,GAAGA,KAAK,GAAG,GAAG,EAAE;EACvC,OAAO,GAAGG,MAAM,IAAIF,SAAS,KAAKC,KAAK,GAAG;AAC5C;;AAEA;AACA;AACA;AACA,SAASE,WAAWA,CAACC,KAAc,EAAW;EAC5C,OAAOA,KAAK,KAAKC,SAAS,IAAID,KAAK,KAAK,IAAI;AAC9C;;AAEA;AACA;AACA;AACA;AACA,SAASE,MAAMA,CAACC,SAAkB,EAAEC,OAAqB,EAAQ;EAC/D,IAAIC,OAAO,IAAIF,SAAS,EAAE;IACxB,MAAM,IAAIG,KAAK,CAAC,
|
|
1
|
+
{"version":3,"names":["buildErrorMessage","usage","fieldName","error","prefix","isUndefined","value","undefined","failIf","condition","message","__DEV__","Error","failIfUndefined","validateString","options","allowEmpty","optional","typedValue","trim","validateRecord","expectedType","typeName","Array","isArray","validateAttributes","exists","attributes","Map","Object","fromEntries","validateConfig","obj","cdpApiKey","assert","string","record","config","validate"],"sourceRoot":"../../../src","sources":["utils/param-validation.ts"],"mappings":";;AAAA;AACA;;AAIA;AACA;AACA;AACA,SAASA,iBAAiBA,CACxBC,KAAyB,EACzBC,SAAiB,EACjBC,KAAa,EACL;EACR,MAAMC,MAAM,GAAGH,KAAK,GAAG,GAAGA,KAAK,GAAG,GAAG,EAAE;EACv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GAAG,QAAQ;EAC1B,MAAMD,KAAK,GAAG,KAAK;EAEnBmB,cAAc,CAACd,KAAK,EAAEJ,SAAS,EAAE;IAC/BmB,YAAY,EAAE,eAAe;IAC7BpB,KAAK,EAAEA;EACT,CAAC,CAAC;EAEF,MAAM+B,GAAG,GAAG1B,KAAsB;EAClCQ,cAAc,CAACkB,GAAG,CAACC,SAAS,EAAE,GAAG/B,SAAS,YAAY,EAAE;IACtDc,UAAU,EAAE,KAAK;IACjBf,KAAK,EAAEA;EACT,CAAC,CAAC;AACJ;;AAEA;AACA;;AAGA,OAAO,MAAMiC,MAKZ,GAAG;EACFC,MAAM,EAAErB,cAAc;EACtBsB,MAAM,EAAEhB,cAAc;EACtBO,UAAU,EAAEF,kBAAkB;EAC9BY,MAAM,EAAEN;AACV,CAAC;AAED,OAAO,MAAMO,QAAQ,GAAG;EACtBjC,WAAW,EAAEA;AACf,CAAC","ignoreList":[]}
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
3
|
+
import { ZixflowInAppMessaging } from "./zixflow-inapp.js";
|
|
4
|
+
import { ZixflowLocation } from "./zixflow-location.js";
|
|
5
|
+
import { ZixflowPushMessaging } from "./zixflow-push.js";
|
|
6
6
|
import { NativeLoggerListener } from "./native-logger-listener.js";
|
|
7
|
-
import { default as NativeModule } from "./specs/modules/
|
|
8
|
-
import {
|
|
7
|
+
import { default as NativeModule } from "./specs/modules/NativeZixflow.js";
|
|
8
|
+
import { ZixflowLogLevel } from "./types/index.js";
|
|
9
9
|
import { callNativeModule, ensureNativeModule } from "./utils/native-bridge.js";
|
|
10
10
|
import { assert, validate } from "./utils/param-validation.js";
|
|
11
11
|
const packageJson = require('../../package.json');
|
|
12
12
|
|
|
13
|
-
// Track whether
|
|
13
|
+
// Track whether Zixflow SDK has been initialized to prevent usage before setup
|
|
14
14
|
let _initialized = false;
|
|
15
15
|
|
|
16
|
-
// Reference to the native
|
|
16
|
+
// Reference to the native Zixflow Data Pipelines module for SDK operations
|
|
17
17
|
const nativeModule = ensureNativeModule(NativeModule);
|
|
18
18
|
|
|
19
19
|
// Wrapper function that ensures SDK is initialized before calling native methods
|
|
@@ -22,11 +22,11 @@ const withNativeModule = fn => {
|
|
|
22
22
|
};
|
|
23
23
|
|
|
24
24
|
/** @public */
|
|
25
|
-
export class
|
|
26
|
-
/** Initialize the
|
|
25
|
+
export class Zixflow {
|
|
26
|
+
/** Initialize the Zixflow SDK with given configuration. */
|
|
27
27
|
static initialize = async config => {
|
|
28
28
|
assert.config(config);
|
|
29
|
-
if (config.logLevel && config.logLevel !==
|
|
29
|
+
if (config.logLevel && config.logLevel !== ZixflowLogLevel.None) {
|
|
30
30
|
NativeLoggerListener.initialize();
|
|
31
31
|
}
|
|
32
32
|
const expoVersion = packageJson.expoVersion ?? '';
|
|
@@ -140,18 +140,18 @@ export class CustomerIO {
|
|
|
140
140
|
};
|
|
141
141
|
|
|
142
142
|
/**
|
|
143
|
-
* Check if the
|
|
143
|
+
* Check if the Zixflow SDK has been initialized.
|
|
144
144
|
* @deprecated This method will be removed in a future version. If you need this functionality, please contact us.
|
|
145
145
|
*/
|
|
146
146
|
static isInitialized = () => _initialized;
|
|
147
|
-
static inAppMessaging = new
|
|
148
|
-
static location = new
|
|
149
|
-
static pushMessaging = new
|
|
147
|
+
static inAppMessaging = new ZixflowInAppMessaging();
|
|
148
|
+
static location = new ZixflowLocation();
|
|
149
|
+
static pushMessaging = new ZixflowPushMessaging();
|
|
150
150
|
}
|
|
151
151
|
|
|
152
152
|
// Initialize native logger when this module loads to ensure it's always available.
|
|
153
|
-
// Since
|
|
153
|
+
// Since this is the main SDK entry point and always imported,
|
|
154
154
|
// this guarantees logger initialization even when native-logger-listener.ts
|
|
155
155
|
// isn't directly accessed, also supporting auto-initialization in Expo apps.
|
|
156
156
|
NativeLoggerListener.initNativeLogger();
|
|
157
|
-
//# sourceMappingURL=
|
|
157
|
+
//# sourceMappingURL=zixflow-cdp.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["ZixflowInAppMessaging","ZixflowLocation","ZixflowPushMessaging","NativeLoggerListener","default","NativeModule","ZixflowLogLevel","callNativeModule","ensureNativeModule","assert","validate","packageJson","require","_initialized","nativeModule","withNativeModule","fn","Zixflow","initialize","config","logLevel","None","expoVersion","args","packageSource","packageVersion","version","promise","native","then","identify","userId","traits","isUndefined","Error","string","allowEmpty","usage","optional","normalizedTraits","attributes","clearIdentify","track","name","properties","normalizedProps","screen","title","setProfileAttributes","normalizedAttrs","setDeviceAttributes","registerDeviceToken","token","deleteDeviceToken","trackMetric","deliveryID","deviceToken","event","isInitialized","inAppMessaging","location","pushMessaging","initNativeLogger"],"sourceRoot":"../../src","sources":["zixflow-cdp.ts"],"mappings":";;AAAA,SAASA,qBAAqB,QAAQ,oBAAiB;AACvD,SAASC,eAAe,QAAQ,uBAAoB;AACpD,SAASC,oBAAoB,QAAQ,mBAAgB;AACrD,SAASC,oBAAoB,QAAQ,6BAA0B;AAC/D,SACEC,OAAO,IAAIC,YAAY,QAElB,kCAA+B;AACtC,SACEC,eAAe,QAKV,kBAAS;AAEhB,SAASC,gBAAgB,EAAEC,kBAAkB,QAAQ,0BAAuB;AAC5E,SAASC,MAAM,EAAEC,QAAQ,QAAQ,6BAA0B;AAE3D,MAAMC,WAAW,GAAGC,OAAO,CAAC,oBAAoB,CAAC;;AAEjD;AACA,IAAIC,YAAY,GAAG,KAAK;;AAExB;AACA,MAAMC,YAAY,GAAGN,kBAAkB,CAACH,YAAY,CAAC;;AAErD;AACA,MAAMU,gBAAgB,GAAOC,EAA8B,IAAQ;EACjE,OAAOT,gBAAgB,CAACO,YAAY,EAAEE,EAAE,CAAC;AAC3C,CAAC;;AAED;AACA,OAAO,MAAMC,OAAO,CAAC;EACnB;EACA,OAAgBC,UAAU,GAAG,MAAOC,MAAqB,IAAK;IAC5DV,MAAM,CAACU,M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KAAK,CACnD,CAAC;EACH,CAAC;;EAED;AACF;AACA;AACA;EACE,OAAgBC,aAAa,GAAGA,CAAA,KAAM7C,YAAY;EAElD,OAAgB8C,cAAc,GAAG,IAAI3D,qBAAqB,CAAC,CAAC;EAC5D,OAAgB4D,QAAQ,GAAG,IAAI3D,eAAe,CAAC,CAAC;EAChD,OAAgB4D,aAAa,GAAG,IAAI3D,oBAAoB,CAAC,CAAC;AAC5D;;AAEA;AACA;AACA;AACA;AACAC,oBAAoB,CAAC2D,gBAAgB,CAAC,CAAC","ignoreList":[]}
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
import { InlineInAppMessageView } from "./components/index.js";
|
|
4
4
|
import { NativeLoggerListener } from "./native-logger-listener.js";
|
|
5
5
|
import { NotificationInbox } from "./notification-inbox.js";
|
|
6
|
-
import
|
|
6
|
+
import NativeZixflowMessagingInApp from "./specs/modules/NativeZixflowMessagingInApp.js";
|
|
7
7
|
import { callNativeModule, ensureNativeModule } from "./utils/native-bridge.js";
|
|
8
8
|
|
|
9
9
|
/**
|
|
@@ -12,8 +12,8 @@ import { callNativeModule, ensureNativeModule } from "./utils/native-bridge.js";
|
|
|
12
12
|
* @internal
|
|
13
13
|
*/
|
|
14
14
|
|
|
15
|
-
// Reference to the native
|
|
16
|
-
const nativeModule = ensureNativeModule(
|
|
15
|
+
// Reference to the native Zixflow Data Pipelines module for SDK operations
|
|
16
|
+
const nativeModule = ensureNativeModule(NativeZixflowMessagingInApp);
|
|
17
17
|
|
|
18
18
|
// Wrapper function that ensures SDK is initialized before calling native methods
|
|
19
19
|
const withNativeModule = fn => {
|
|
@@ -25,7 +25,7 @@ const withNativeModule = fn => {
|
|
|
25
25
|
*
|
|
26
26
|
* @public
|
|
27
27
|
*/
|
|
28
|
-
class
|
|
28
|
+
class ZixflowInAppMessaging {
|
|
29
29
|
registerEventsListener(listener) {
|
|
30
30
|
const emitter = data => {
|
|
31
31
|
// Convert raw native payload to InAppMessageEvent
|
|
@@ -88,5 +88,5 @@ class InAppMessageEvent {
|
|
|
88
88
|
// Export in-app messaging types and components for simplified imports
|
|
89
89
|
|
|
90
90
|
export { NotificationInbox } from "./notification-inbox.js";
|
|
91
|
-
export {
|
|
92
|
-
//# sourceMappingURL=
|
|
91
|
+
export { ZixflowInAppMessaging, InAppMessageEvent, InlineInAppMessageView };
|
|
92
|
+
//# sourceMappingURL=zixflow-inapp.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["InlineInAppMessageView","NativeLoggerListener","NotificationInbox","NativeZixflowMessagingInApp","callNativeModule","ensureNativeModule","nativeModule","withNativeModule","fn","ZixflowInAppMessaging","registerEventsListener","listener","emitter","data","event","InAppMessageEvent","eventType","messageId","deliveryId","actionValue","actionName","native","onInAppEventReceived","error","warn","remove","key","subscriber","dismissMessage","inbox","_notificationInbox","constructor"],"sourceRoot":"../../src","sources":["zixflow-inapp.ts"],"mappings":";;AACA,SAASA,sBAAsB,QAAQ,uBAAc;AACrD,SAASC,oBAAoB,QAAQ,6BAA0B;AAC/D,SACEC,iBAAiB,QAEZ,yBAAsB;AAC7B,OAAOC,2BAA2B,MAE3B,gDAA6C;AAEpD,SAASC,gBAAgB,EAAEC,kBAAkB,QAAQ,0BAAuB;;AAE5E;AACA;AACA;AACA;AACA;;AAMA;AACA,MAAMC,YAAY,GAAGD,kBAAkB,CAACF,2BAA2B,CAAC;;AAEpE;AACA,MAAMI,gBAAgB,GAAOC,EAA8B,IAAQ;EACjE,OAAOJ,gBAAgB,CAACE,YAAY,EAAEE,EAAE,CAAC;AAC3C,CAAC;;AAED;AACA;AACA;AACA;AACA;AACA,MAAMC,qBAAqB,CAA4B;EAGrDC,sBAAsBA,CACpBC,QAA4C,EACzB;IACnB,MAAMC,OAAO,GAAIC,IAAS,IAAK;MAC7B;MACA,MAAMC,KAAK,GAAG,IAAIC,iBAAiB,CACjCF,IAAI,CAACG,SAAS,EACdH,IAAI,CAACI,SAAS,EACdJ,IAAI,CAACK,UAA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