apps-sdk 1.1.10 → 1.1.13
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/package.json
CHANGED
|
@@ -222,7 +222,7 @@ class PayWall extends React.Component {
|
|
|
222
222
|
switch(true) {
|
|
223
223
|
case data.eventName === 'on_boarding' && data.eventValue.toString().substring(0, 4) === 'step':
|
|
224
224
|
const stepNumber = data.eventValue.toString().substring(4);
|
|
225
|
-
MixPanel.trackEvent('Onboarding Screen
|
|
225
|
+
MixPanel.trackEvent('Onboarding Screen Steps', {
|
|
226
226
|
"onboarding_id": config.PAYWALL_DATA.others.on_boarding.dsn_id.toString(),
|
|
227
227
|
"onboarding_total_steps": 4,
|
|
228
228
|
"onboarding_step": stepNumber,
|
|
@@ -40,7 +40,7 @@ class MixPanel {
|
|
|
40
40
|
}
|
|
41
41
|
}
|
|
42
42
|
|
|
43
|
-
async trackEvent(eventName, properties = {}) {
|
|
43
|
+
async trackEvent(eventName, properties = {}, forceSend = false) {
|
|
44
44
|
if (!this.mixpanel) {
|
|
45
45
|
console.log('Mixpanel is not initialized');
|
|
46
46
|
return;
|
|
@@ -49,7 +49,7 @@ class MixPanel {
|
|
|
49
49
|
try {
|
|
50
50
|
if (!this.devMode) {
|
|
51
51
|
const trackingPermissionAnswered = await Storage.getData('TRACKING_PERMISSION_ANSWERED');
|
|
52
|
-
if (config.TRACKING_ACTIVE || !trackingPermissionAnswered) {
|
|
52
|
+
if (config.TRACKING_ACTIVE || !trackingPermissionAnswered || forceSend) {
|
|
53
53
|
await this.mixpanel.track(eventName, properties);
|
|
54
54
|
config.DEBUG_MODE && console.log(`MixPanel Event tracked: ${eventName} with properties:`, properties);
|
|
55
55
|
} else {
|
|
@@ -81,10 +81,10 @@ class MixPanel {
|
|
|
81
81
|
if (!this.devMode) {
|
|
82
82
|
const trackingPermissionAnswered = await Storage.getData('TRACKING_PERMISSION_ANSWERED');
|
|
83
83
|
if (config.TRACKING_ACTIVE || !trackingPermissionAnswered) {
|
|
84
|
-
const distinctId = await this.getDistinctID();
|
|
85
|
-
const superProperties = { ...properties, distinct_id: distinctId };
|
|
86
|
-
await this.mixpanel.registerSuperProperties(
|
|
87
|
-
config.DEBUG_MODE && console.log('MixPanel Super Properties registered:',
|
|
84
|
+
// const distinctId = await this.getDistinctID();
|
|
85
|
+
// const superProperties = { ...properties, distinct_id: distinctId };
|
|
86
|
+
await this.mixpanel.registerSuperProperties(properties);
|
|
87
|
+
config.DEBUG_MODE && console.log('MixPanel Super Properties registered:', properties);
|
|
88
88
|
} else {
|
|
89
89
|
config.DEBUG_MODE && console.log('MixPanel Super Properties not registered due to tracking permission:', properties);
|
|
90
90
|
}
|
|
@@ -104,10 +104,10 @@ class MixPanel {
|
|
|
104
104
|
|
|
105
105
|
try {
|
|
106
106
|
if (!this.devMode) {
|
|
107
|
-
const distinctId = await this.getDistinctID();
|
|
108
|
-
const superProperties = { ...properties, distinct_id: distinctId };
|
|
109
|
-
await this.mixpanel.registerSuperPropertiesOnce(
|
|
110
|
-
config.DEBUG_MODE && console.log('MixPanel Super Properties appended:',
|
|
107
|
+
// const distinctId = await this.getDistinctID();
|
|
108
|
+
// const superProperties = { ...properties, distinct_id: distinctId };
|
|
109
|
+
await this.mixpanel.registerSuperPropertiesOnce(properties);
|
|
110
|
+
config.DEBUG_MODE && console.log('MixPanel Super Properties appended:', properties);
|
|
111
111
|
} else {
|
|
112
112
|
config.DEBUG_MODE && console.log('MixPanel Super Properties appended but not send (DEV_MODE ON):', properties);
|
|
113
113
|
}
|
|
@@ -142,10 +142,11 @@ class MixPanel {
|
|
|
142
142
|
|
|
143
143
|
try {
|
|
144
144
|
if (!this.devMode) {
|
|
145
|
-
const distinctId = await this.getDistinctID();
|
|
146
|
-
const userProperties = { [propertyName]: propertyValue, distinct_id: distinctId };
|
|
147
|
-
await this.mixpanel.getPeople().set(
|
|
148
|
-
config.DEBUG_MODE && console.log(`MixPanel User property set: ${propertyName} = ${propertyValue}
|
|
145
|
+
// const distinctId = await this.getDistinctID();
|
|
146
|
+
// const userProperties = { [propertyName]: propertyValue, distinct_id: distinctId };
|
|
147
|
+
await this.mixpanel.getPeople().set(propertyName, propertyValue);
|
|
148
|
+
config.DEBUG_MODE && console.log(`MixPanel User property set: ${propertyName} = ${propertyValue}`);
|
|
149
|
+
// config.DEBUG_MODE && console.log(`MixPanel User property set: ${propertyName} = ${propertyValue}, distinct_id = ${distinctId}`);
|
|
149
150
|
} else {
|
|
150
151
|
config.DEBUG_MODE && console.log(`MixPanel User property set but not send (DEV_MODE ON): ${propertyName} = ${propertyValue}`);
|
|
151
152
|
}
|
|
@@ -13,7 +13,7 @@ class HomeActions {
|
|
|
13
13
|
}
|
|
14
14
|
|
|
15
15
|
async itemCallback(itemCallbackFunction) {
|
|
16
|
-
console.log("itemCallback",
|
|
16
|
+
console.log("itemCallback", itemCallbackFunction);
|
|
17
17
|
useQuickActionCallback(action => {
|
|
18
18
|
if (action) {
|
|
19
19
|
console.log("action", action);
|