@applicaster/zapp-react-native-utils 12.0.0-rc.70 → 12.0.0-rc.72
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.
|
@@ -12,6 +12,11 @@ import {
|
|
|
12
12
|
sendSearchExecutedEvent,
|
|
13
13
|
} from "./searchEvents";
|
|
14
14
|
|
|
15
|
+
import {
|
|
16
|
+
sendShareInitiatedEvent,
|
|
17
|
+
sendShareSuccessEvent,
|
|
18
|
+
} from "./sendShareEvent";
|
|
19
|
+
|
|
15
20
|
export {
|
|
16
21
|
sendScreenEvent,
|
|
17
22
|
sendOnClickEvent,
|
|
@@ -24,4 +29,6 @@ export {
|
|
|
24
29
|
sendDownloadsEvent,
|
|
25
30
|
sendSearchCanceledEvent,
|
|
26
31
|
sendSearchExecutedEvent,
|
|
32
|
+
sendShareInitiatedEvent,
|
|
33
|
+
sendShareSuccessEvent,
|
|
27
34
|
};
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { log_debug } from "../logger";
|
|
2
|
+
import { postAnalyticEvent } from "../manager";
|
|
3
|
+
import { ANALYTICS_CORE_EVENTS } from "../events";
|
|
4
|
+
|
|
5
|
+
export const sendShareInitiatedEvent = (analyticsProps) => {
|
|
6
|
+
const eventName = ANALYTICS_CORE_EVENTS.SHARE_INITIATED;
|
|
7
|
+
postAnalyticEvent(eventName, analyticsProps);
|
|
8
|
+
|
|
9
|
+
log_debug(`sendShareInitiatedEvent: send event: ${eventName}`, {
|
|
10
|
+
analyticsProps,
|
|
11
|
+
});
|
|
12
|
+
};
|
|
13
|
+
|
|
14
|
+
export const sendShareSuccessEvent = (analyticsProps) => {
|
|
15
|
+
const eventName = ANALYTICS_CORE_EVENTS.SHARE_SUCCESS;
|
|
16
|
+
postAnalyticEvent(eventName, analyticsProps);
|
|
17
|
+
|
|
18
|
+
log_debug(`sendShareSuccessEvent: send event: ${eventName}`, {
|
|
19
|
+
analyticsProps,
|
|
20
|
+
});
|
|
21
|
+
};
|
package/analyticsUtils/events.ts
CHANGED
|
@@ -28,11 +28,17 @@ export const SEARCH_EVENTS = {
|
|
|
28
28
|
SEARCH_CANCELED: "search_canceled",
|
|
29
29
|
};
|
|
30
30
|
|
|
31
|
+
export const SHARE_EVENTS = {
|
|
32
|
+
SHARE_INITIATED: "share_initiated",
|
|
33
|
+
SHARE_SUCCESS: "share_success",
|
|
34
|
+
};
|
|
35
|
+
|
|
31
36
|
export const ANALYTICS_CORE_EVENTS = {
|
|
32
37
|
...LEGACY_EVENTS,
|
|
33
38
|
...SCREEN_VIEW_EVENTS,
|
|
34
39
|
...TAPPING_EVENTS,
|
|
35
40
|
...SEARCH_EVENTS,
|
|
41
|
+
...SHARE_EVENTS,
|
|
36
42
|
};
|
|
37
43
|
|
|
38
44
|
export const WEBVIEW_EVENTS = {
|
package/analyticsUtils/index.tsx
CHANGED
|
@@ -20,6 +20,8 @@ import {
|
|
|
20
20
|
sendScreenEvent,
|
|
21
21
|
sendSearchCanceledEvent,
|
|
22
22
|
sendSearchExecutedEvent,
|
|
23
|
+
sendShareInitiatedEvent,
|
|
24
|
+
sendShareSuccessEvent,
|
|
23
25
|
} from "./AnalyticsEvents";
|
|
24
26
|
|
|
25
27
|
import { postAnalyticEvent } from "./manager";
|
|
@@ -70,6 +72,8 @@ type AnalyticsFunctions = {
|
|
|
70
72
|
}) => void;
|
|
71
73
|
sendSearchCanceledEvent: (props: AnalyticsDefaultProperties) => void;
|
|
72
74
|
sendSearchExecutedEvent: (props: AnalyticsDefaultProperties) => void;
|
|
75
|
+
sendShareInitiatedEvent: (props: AnalyticsDefaultProperties) => void;
|
|
76
|
+
sendShareSuccessEvent: (props: AnalyticsDefaultProperties) => void;
|
|
73
77
|
};
|
|
74
78
|
|
|
75
79
|
type GetAnalyticsFunctions = (
|
|
@@ -108,6 +112,8 @@ export function getAnalyticsFunctions({
|
|
|
108
112
|
sendDownloadsEvent,
|
|
109
113
|
sendSearchCanceledEvent,
|
|
110
114
|
sendSearchExecutedEvent,
|
|
115
|
+
sendShareInitiatedEvent,
|
|
116
|
+
sendShareSuccessEvent,
|
|
111
117
|
};
|
|
112
118
|
}
|
|
113
119
|
|
|
@@ -111,7 +111,7 @@ export class PlayerNative extends Player {
|
|
|
111
111
|
return;
|
|
112
112
|
}
|
|
113
113
|
|
|
114
|
-
const newPosition = R.clamp(0,
|
|
114
|
+
const newPosition = R.clamp(0, this.playerState.seekableDuration, position);
|
|
115
115
|
|
|
116
116
|
if (
|
|
117
117
|
!this.invokeNativeFunction(
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@applicaster/zapp-react-native-utils",
|
|
3
|
-
"version": "12.0.0-rc.
|
|
3
|
+
"version": "12.0.0-rc.72",
|
|
4
4
|
"description": "Applicaster Zapp React Native utilities package",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"types": "index.d.ts",
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
},
|
|
29
29
|
"homepage": "https://github.com/applicaster/quickbrick#readme",
|
|
30
30
|
"dependencies": {
|
|
31
|
-
"@applicaster/applicaster-types": "12.0.0-rc.
|
|
31
|
+
"@applicaster/applicaster-types": "12.0.0-rc.72",
|
|
32
32
|
"buffer": "^5.2.1",
|
|
33
33
|
"camelize": "^1.0.0",
|
|
34
34
|
"create-react-context": "^0.2.3",
|