notifly-sdk 2.3.5 → 2.3.7
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/index.js +1 -0
- package/package.json +1 -1
- package/src/constant.js +1 -1
- package/src/in_app_message.js +15 -11
package/index.js
CHANGED
|
@@ -127,6 +127,7 @@ exports.initialize = async function (prjId, userName, password, useCustomClickHa
|
|
|
127
127
|
|
|
128
128
|
// custom push click handler
|
|
129
129
|
if (!useCustomClickHandler) {
|
|
130
|
+
await new Promise((resolve) => setTimeout(resolve, 500));
|
|
130
131
|
const initialNotification = await messaging().getInitialNotification();
|
|
131
132
|
if (initialNotification) {
|
|
132
133
|
await clickHandler(initialNotification);
|
package/package.json
CHANGED
package/src/constant.js
CHANGED
package/src/in_app_message.js
CHANGED
|
@@ -106,13 +106,13 @@ export async function showInAppMessage(data, openedInAppWebViewCount) {
|
|
|
106
106
|
openedInAppWebViewCount.count = openedInAppWebViewCount.count - 1;
|
|
107
107
|
logEvent(
|
|
108
108
|
'survey_submit_button_click', {
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
109
|
+
type: 'message_event',
|
|
110
|
+
channel: 'in-app-message',
|
|
111
|
+
button_name: message.button_name,
|
|
112
|
+
campaign_id: data.campaign_id,
|
|
113
|
+
notifly_message_id: data.notifly_message_id,
|
|
114
|
+
notifly_extra_data: message.extra_data,
|
|
115
|
+
},
|
|
116
116
|
null,
|
|
117
117
|
true
|
|
118
118
|
);
|
|
@@ -132,12 +132,16 @@ export async function showInAppMessage(data, openedInAppWebViewCount) {
|
|
|
132
132
|
isVisible={true}
|
|
133
133
|
transparent={true}
|
|
134
134
|
onBackdropPress={() => {
|
|
135
|
-
|
|
136
|
-
|
|
135
|
+
if (modalProperties?.dismissCTATapped) {
|
|
136
|
+
openedInAppWebViewCount.count = openedInAppWebViewCount.count - 1;
|
|
137
|
+
modal.destroy();
|
|
138
|
+
}
|
|
137
139
|
}}
|
|
138
140
|
onBackButtonPress={() => {
|
|
139
|
-
|
|
140
|
-
|
|
141
|
+
if (modalProperties?.dismissCTATapped) {
|
|
142
|
+
openedInAppWebViewCount.count = openedInAppWebViewCount.count - 1;
|
|
143
|
+
modal.destroy();
|
|
144
|
+
}
|
|
141
145
|
}}
|
|
142
146
|
backdropOpacity={backdropOpacity}
|
|
143
147
|
style={webViewProps.modalStyle}
|