@luciq/react-native 18.2.0 → 19.0.0-286-SNAPSHOT
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/CHANGELOG.md +17 -5
- package/android/build.gradle +1 -1
- package/android/native.gradle +1 -1
- package/android/sourcemaps.gradle +41 -12
- package/android/src/main/java/ai/luciq/reactlibrary/RNLuciqAPMModule.java +20 -1
- package/bin/config/migration-config.json +5 -5
- package/bin/index.js +0 -0
- package/cli/config/migration-config.json +5 -5
- package/dist/modules/APM.d.ts +5 -0
- package/dist/modules/APM.js +19 -0
- package/dist/modules/BugReporting.js +38 -0
- package/dist/modules/CrashReporting.js +3 -0
- package/dist/modules/FeatureRequests.js +6 -0
- package/dist/modules/Luciq.js +58 -0
- package/dist/modules/NetworkLogger.js +21 -3
- package/dist/modules/Replies.js +15 -0
- package/dist/modules/SessionReplay.js +6 -0
- package/dist/modules/Surveys.js +10 -0
- package/dist/native/NativeAPM.d.ts +1 -0
- package/ios/RNLuciq/LuciqAPMBridge.h +2 -0
- package/ios/RNLuciq/LuciqAPMBridge.m +4 -1
- package/ios/native.rb +1 -1
- package/package.json +1 -2
- package/src/modules/APM.ts +20 -0
- package/src/modules/BugReporting.ts +38 -0
- package/src/modules/CrashReporting.ts +3 -0
- package/src/modules/FeatureRequests.ts +6 -0
- package/src/modules/Luciq.ts +58 -0
- package/src/modules/NetworkLogger.ts +21 -3
- package/src/modules/Replies.ts +15 -0
- package/src/modules/SessionReplay.ts +6 -0
- package/src/modules/Surveys.ts +10 -0
- package/src/native/NativeAPM.ts +3 -0
- package/plugin/build/index.js +0 -42078
package/src/modules/Surveys.ts
CHANGED
|
@@ -15,6 +15,7 @@ export type { Survey };
|
|
|
15
15
|
* @param isEnabled A boolean to set whether Luciq Surveys is enabled or disabled.
|
|
16
16
|
*/
|
|
17
17
|
export const setEnabled = (isEnabled: boolean) => {
|
|
18
|
+
console.log('[LCQ-RN] Surveys.setEnabled called', { isEnabled });
|
|
18
19
|
NativeSurveys.setEnabled(isEnabled);
|
|
19
20
|
};
|
|
20
21
|
|
|
@@ -25,6 +26,7 @@ export const setEnabled = (isEnabled: boolean) => {
|
|
|
25
26
|
* in the current session.
|
|
26
27
|
*/
|
|
27
28
|
export const showSurveyIfAvailable = () => {
|
|
29
|
+
console.log('[LCQ-RN] Surveys.showSurveyIfAvailable called');
|
|
28
30
|
NativeSurveys.showSurveysIfAvailable();
|
|
29
31
|
};
|
|
30
32
|
|
|
@@ -32,6 +34,7 @@ export const showSurveyIfAvailable = () => {
|
|
|
32
34
|
* Returns an array containing the available surveys.
|
|
33
35
|
*/
|
|
34
36
|
export const getAvailableSurveys = async (): Promise<Survey[] | null> => {
|
|
37
|
+
console.log('[LCQ-RN] Surveys.getAvailableSurveys called');
|
|
35
38
|
const surveys = await NativeSurveys.getAvailableSurveys();
|
|
36
39
|
|
|
37
40
|
return surveys;
|
|
@@ -43,6 +46,7 @@ export const getAvailableSurveys = async (): Promise<Survey[] | null> => {
|
|
|
43
46
|
* surveys auto showing are enabled or not.
|
|
44
47
|
*/
|
|
45
48
|
export const setAutoShowingEnabled = (autoShowingSurveysEnabled: boolean) => {
|
|
49
|
+
console.log('[LCQ-RN] Surveys.setAutoShowingEnabled called', { autoShowingSurveysEnabled });
|
|
46
50
|
NativeSurveys.setAutoShowingEnabled(autoShowingSurveysEnabled);
|
|
47
51
|
};
|
|
48
52
|
|
|
@@ -54,6 +58,7 @@ export const setAutoShowingEnabled = (autoShowingSurveysEnabled: boolean) => {
|
|
|
54
58
|
* presenting the survey's UI.
|
|
55
59
|
*/
|
|
56
60
|
export const setOnShowHandler = (onShowHandler: () => void) => {
|
|
61
|
+
console.log('[LCQ-RN] Surveys.setOnShowHandler called');
|
|
57
62
|
emitter.addListener(NativeEvents.WILL_SHOW_SURVEY_HANDLER, onShowHandler);
|
|
58
63
|
NativeSurveys.setOnShowHandler(onShowHandler);
|
|
59
64
|
};
|
|
@@ -66,6 +71,7 @@ export const setOnShowHandler = (onShowHandler: () => void) => {
|
|
|
66
71
|
* the survey's UI is dismissed.
|
|
67
72
|
*/
|
|
68
73
|
export const setOnDismissHandler = (onDismissHandler: () => void) => {
|
|
74
|
+
console.log('[LCQ-RN] Surveys.setOnDismissHandler called');
|
|
69
75
|
emitter.addListener(NativeEvents.DID_DISMISS_SURVEY_HANDLER, onDismissHandler);
|
|
70
76
|
NativeSurveys.setOnDismissHandler(onDismissHandler);
|
|
71
77
|
};
|
|
@@ -78,6 +84,7 @@ export const setOnDismissHandler = (onDismissHandler: () => void) => {
|
|
|
78
84
|
*
|
|
79
85
|
*/
|
|
80
86
|
export const showSurvey = (surveyToken: string) => {
|
|
87
|
+
console.log('[LCQ-RN] Surveys.showSurvey called', { surveyToken });
|
|
81
88
|
NativeSurveys.showSurvey(surveyToken);
|
|
82
89
|
};
|
|
83
90
|
|
|
@@ -89,6 +96,7 @@ export const showSurvey = (surveyToken: string) => {
|
|
|
89
96
|
*
|
|
90
97
|
*/
|
|
91
98
|
export const hasRespondedToSurvey = async (surveyToken: string): Promise<boolean | null> => {
|
|
99
|
+
console.log('[LCQ-RN] Surveys.hasRespondedToSurvey called', { surveyToken });
|
|
92
100
|
const hasResponded = await NativeSurveys.hasRespondedToSurvey(surveyToken);
|
|
93
101
|
|
|
94
102
|
return hasResponded;
|
|
@@ -101,6 +109,7 @@ export const hasRespondedToSurvey = async (surveyToken: string): Promise<boolean
|
|
|
101
109
|
* welcome screen should show.
|
|
102
110
|
*/
|
|
103
111
|
export const setShouldShowWelcomeScreen = (shouldShowWelcomeScreen: boolean) => {
|
|
112
|
+
console.log('[LCQ-RN] Surveys.setShouldShowWelcomeScreen called', { shouldShowWelcomeScreen });
|
|
104
113
|
NativeSurveys.setShouldShowWelcomeScreen(shouldShowWelcomeScreen);
|
|
105
114
|
};
|
|
106
115
|
|
|
@@ -112,6 +121,7 @@ export const setShouldShowWelcomeScreen = (shouldShowWelcomeScreen: boolean) =>
|
|
|
112
121
|
*/
|
|
113
122
|
|
|
114
123
|
export const setAppStoreURL = (appStoreURL: string) => {
|
|
124
|
+
console.log('[LCQ-RN] Surveys.setAppStoreURL called', { appStoreURL });
|
|
115
125
|
if (Platform.OS === 'ios') {
|
|
116
126
|
NativeSurveys.setAppStoreURL(appStoreURL);
|
|
117
127
|
}
|
package/src/native/NativeAPM.ts
CHANGED
|
@@ -44,6 +44,9 @@ export interface ApmNativeModule extends NativeModule {
|
|
|
44
44
|
startUITrace(name: string): void;
|
|
45
45
|
endUITrace(): void;
|
|
46
46
|
lcqSleep(): void;
|
|
47
|
+
|
|
48
|
+
// Screen Rendering //
|
|
49
|
+
setScreenRenderingEnabled(isEnabled: boolean): void;
|
|
47
50
|
}
|
|
48
51
|
|
|
49
52
|
export const NativeAPM = NativeModules.LCQAPM;
|