@luciq/react-native 19.0.0-286-SNAPSHOT → 19.1.0

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.
Files changed (39) hide show
  1. package/CHANGELOG.md +13 -1
  2. package/android/native.gradle +1 -1
  3. package/android/src/main/java/ai/luciq/reactlibrary/ArgsRegistry.java +14 -0
  4. package/android/src/main/java/ai/luciq/reactlibrary/RNLuciqSessionReplayModule.java +51 -0
  5. package/bin/index.js +0 -0
  6. package/dist/modules/APM.js +0 -12
  7. package/dist/modules/BugReporting.js +0 -38
  8. package/dist/modules/CrashReporting.js +0 -3
  9. package/dist/modules/FeatureRequests.js +0 -6
  10. package/dist/modules/Luciq.js +0 -58
  11. package/dist/modules/NetworkLogger.js +3 -21
  12. package/dist/modules/Replies.js +0 -15
  13. package/dist/modules/SessionReplay.d.ts +54 -0
  14. package/dist/modules/SessionReplay.js +59 -6
  15. package/dist/modules/Surveys.js +0 -10
  16. package/dist/native/NativeConstants.d.ts +11 -1
  17. package/dist/native/NativeSessionReplay.d.ts +3 -0
  18. package/dist/utils/Enums.d.ts +37 -0
  19. package/dist/utils/Enums.js +39 -0
  20. package/ios/RNLuciq/ArgsRegistry.h +2 -0
  21. package/ios/RNLuciq/ArgsRegistry.m +18 -0
  22. package/ios/RNLuciq/LuciqSessionReplayBridge.h +6 -0
  23. package/ios/RNLuciq/LuciqSessionReplayBridge.m +11 -0
  24. package/ios/RNLuciq/RCTConvert+LuciqEnums.m +14 -0
  25. package/ios/native.rb +1 -1
  26. package/package.json +2 -1
  27. package/plugin/build/index.js +42078 -0
  28. package/src/modules/APM.ts +0 -12
  29. package/src/modules/BugReporting.ts +0 -38
  30. package/src/modules/CrashReporting.ts +0 -3
  31. package/src/modules/FeatureRequests.ts +0 -6
  32. package/src/modules/Luciq.ts +0 -58
  33. package/src/modules/NetworkLogger.ts +3 -21
  34. package/src/modules/Replies.ts +0 -15
  35. package/src/modules/SessionReplay.ts +63 -6
  36. package/src/modules/Surveys.ts +0 -10
  37. package/src/native/NativeConstants.ts +15 -1
  38. package/src/native/NativeSessionReplay.ts +3 -0
  39. package/src/utils/Enums.ts +39 -0
@@ -8,7 +8,6 @@ import { NativeLuciq } from '../native/NativeLuciq';
8
8
  * @param isEnabled
9
9
  */
10
10
  export const setEnabled = (isEnabled: boolean) => {
11
- console.log('[LCQ-RN] APM.setEnabled called', { isEnabled });
12
11
  NativeAPM.setEnabled(isEnabled);
13
12
  };
14
13
 
@@ -18,7 +17,6 @@ export const setEnabled = (isEnabled: boolean) => {
18
17
  * @param isEnabled
19
18
  */
20
19
  export const setAppLaunchEnabled = (isEnabled: boolean) => {
21
- console.log('[LCQ-RN] APM.setAppLaunchEnabled called', { isEnabled });
22
20
  NativeAPM.setAppLaunchEnabled(isEnabled);
23
21
  };
24
22
 
@@ -28,7 +26,6 @@ export const setAppLaunchEnabled = (isEnabled: boolean) => {
28
26
  * You can then view this data with the automatic cold app launch.
29
27
  */
30
28
  export const endAppLaunch = () => {
31
- console.log('[LCQ-RN] APM.endAppLaunch called');
32
29
  NativeAPM.endAppLaunch();
33
30
  };
34
31
 
@@ -37,7 +34,6 @@ export const endAppLaunch = () => {
37
34
  * @param isEnabled - a boolean indicates either iOS monitoring is enabled or disabled.
38
35
  */
39
36
  export const setNetworkEnabledIOS = (isEnabled: boolean) => {
40
- console.log('[LCQ-RN] APM.setNetworkEnabledIOS called', { isEnabled });
41
37
  if (Platform.OS === 'ios') {
42
38
  NativeLuciq.setNetworkLoggingEnabled(isEnabled);
43
39
  }
@@ -48,7 +44,6 @@ export const setNetworkEnabledIOS = (isEnabled: boolean) => {
48
44
  * @param isEnabled
49
45
  */
50
46
  export const setAutoUITraceEnabled = (isEnabled: boolean) => {
51
- console.log('[LCQ-RN] APM.setAutoUITraceEnabled called', { isEnabled });
52
47
  NativeAPM.setAutoUITraceEnabled(isEnabled);
53
48
  };
54
49
 
@@ -64,7 +59,6 @@ export const setAutoUITraceEnabled = (isEnabled: boolean) => {
64
59
  * and the Luciq SDK is initialized.
65
60
  */
66
61
  export const startFlow = (name: string) => {
67
- console.log('[LCQ-RN] APM.startFlow called', { name });
68
62
  NativeAPM.startFlow(name);
69
63
  };
70
64
 
@@ -74,7 +68,6 @@ export const startFlow = (name: string) => {
74
68
  * @param name - The name of the AppFlow to end. It cannot be an empty string or null.
75
69
  */
76
70
  export const endFlow = (name: string) => {
77
- console.log('[LCQ-RN] APM.endFlow called', { name });
78
71
  NativeAPM.endFlow(name);
79
72
  };
80
73
 
@@ -96,7 +89,6 @@ export const endFlow = (name: string) => {
96
89
  */
97
90
 
98
91
  export const setFlowAttribute = (name: string, key: string, value?: string | null) => {
99
- console.log('[LCQ-RN] APM.setFlowAttribute called', { name, key, value });
100
92
  NativeAPM.setFlowAttribute(name, key, value);
101
93
  };
102
94
 
@@ -107,7 +99,6 @@ export const setFlowAttribute = (name: string, key: string, value?: string | nul
107
99
  * the specific UI trace within the application.
108
100
  */
109
101
  export const startUITrace = (name: string) => {
110
- console.log('[LCQ-RN] APM.startUITrace called', { name });
111
102
  NativeAPM.startUITrace(name);
112
103
  };
113
104
 
@@ -115,7 +106,6 @@ export const startUITrace = (name: string) => {
115
106
  * Ends the currently running custom trace.
116
107
  */
117
108
  export const endUITrace = () => {
118
- console.log('[LCQ-RN] APM.endUITrace called');
119
109
  NativeAPM.endUITrace();
120
110
  };
121
111
 
@@ -123,7 +113,6 @@ export const endUITrace = () => {
123
113
  * Used for internal testing.
124
114
  */
125
115
  export const _lcqSleep = () => {
126
- console.log('[LCQ-RN] APM._lcqSleep called');
127
116
  NativeAPM.lcqSleep();
128
117
  };
129
118
 
@@ -132,6 +121,5 @@ export const _lcqSleep = () => {
132
121
  * @param isEnabled
133
122
  */
134
123
  export const setScreenRenderingEnabled = (isEnabled: boolean) => {
135
- console.log('[LCQ-RN] APM.setScreenRenderingEnabled called', { isEnabled });
136
124
  NativeAPM.setScreenRenderingEnabled(isEnabled);
137
125
  };
@@ -18,7 +18,6 @@ import type {
18
18
  * @param isEnabled
19
19
  */
20
20
  export const setEnabled = (isEnabled: boolean) => {
21
- console.log('[LCQ-RN] BugReporting.setEnabled called', { isEnabled });
22
21
  NativeBugReporting.setEnabled(isEnabled);
23
22
  };
24
23
 
@@ -28,7 +27,6 @@ export const setEnabled = (isEnabled: boolean) => {
28
27
  * @param events Array of events that invokes the feedback form.
29
28
  */
30
29
  export const setInvocationEvents = (events: InvocationEvent[]) => {
31
- console.log('[LCQ-RN] BugReporting.setInvocationEvents called', { events });
32
30
  NativeBugReporting.setInvocationEvents(events);
33
31
  };
34
32
 
@@ -38,7 +36,6 @@ export const setInvocationEvents = (events: InvocationEvent[]) => {
38
36
  * @param options Array of invocation options
39
37
  */
40
38
  export const setOptions = (options: InvocationOption[]) => {
41
- console.log('[LCQ-RN] BugReporting.setOptions called', { options });
42
39
  NativeBugReporting.setOptions(options);
43
40
  };
44
41
 
@@ -49,7 +46,6 @@ export const setOptions = (options: InvocationOption[]) => {
49
46
  * @param handler A callback that gets executed before invoking the SDK
50
47
  */
51
48
  export const onInvokeHandler = (handler: () => void) => {
52
- console.log('[LCQ-RN] BugReporting.onInvokeHandler called');
53
49
  emitter.addListener(NativeEvents.ON_INVOKE_HANDLER, handler);
54
50
  NativeBugReporting.setOnInvokeHandler(handler);
55
51
  };
@@ -63,7 +59,6 @@ export const onInvokeHandler = (handler: () => void) => {
63
59
  export const onSDKDismissedHandler = (
64
60
  handler: (dismissType: DismissType, reportType: ReportType) => void,
65
61
  ) => {
66
- console.log('[LCQ-RN] BugReporting.onSDKDismissedHandler called');
67
62
  emitter.addListener(NativeEvents.ON_DISMISS_HANDLER, (payload) => {
68
63
  handler(payload.dismissType, payload.reportType);
69
64
  });
@@ -76,7 +71,6 @@ export const onSDKDismissedHandler = (
76
71
  * @param threshold Threshold for iPhone.
77
72
  */
78
73
  export const setShakingThresholdForiPhone = (threshold: number) => {
79
- console.log('[LCQ-RN] BugReporting.setShakingThresholdForiPhone called', { threshold });
80
74
  if (Platform.OS === 'ios') {
81
75
  NativeBugReporting.setShakingThresholdForiPhone(threshold);
82
76
  }
@@ -88,7 +82,6 @@ export const setShakingThresholdForiPhone = (threshold: number) => {
88
82
  * @param threshold Threshold for iPad.
89
83
  */
90
84
  export const setShakingThresholdForiPad = (threshold: number) => {
91
- console.log('[LCQ-RN] BugReporting.setShakingThresholdForiPad called', { threshold });
92
85
  if (Platform.OS === 'ios') {
93
86
  NativeBugReporting.setShakingThresholdForiPad(threshold);
94
87
  }
@@ -102,7 +95,6 @@ export const setShakingThresholdForiPad = (threshold: number) => {
102
95
  * @param threshold Threshold for android devices.
103
96
  */
104
97
  export const setShakingThresholdForAndroid = (threshold: number) => {
105
- console.log('[LCQ-RN] BugReporting.setShakingThresholdForAndroid called', { threshold });
106
98
  if (Platform.OS === 'android') {
107
99
  NativeBugReporting.setShakingThresholdForAndroid(threshold);
108
100
  }
@@ -115,7 +107,6 @@ export const setShakingThresholdForAndroid = (threshold: number) => {
115
107
  * enable it with required or with optional fields.
116
108
  */
117
109
  export const setExtendedBugReportMode = (mode: ExtendedBugReportMode) => {
118
- console.log('[LCQ-RN] BugReporting.setExtendedBugReportMode called', { mode });
119
110
  NativeBugReporting.setExtendedBugReportMode(mode);
120
111
  };
121
112
 
@@ -124,7 +115,6 @@ export const setExtendedBugReportMode = (mode: ExtendedBugReportMode) => {
124
115
  * @param types Array of reportTypes
125
116
  */
126
117
  export const setReportTypes = (types: ReportType[]) => {
127
- console.log('[LCQ-RN] BugReporting.setReportTypes called', { types });
128
118
  NativeBugReporting.setReportTypes(types);
129
119
  };
130
120
 
@@ -134,7 +124,6 @@ export const setReportTypes = (types: ReportType[]) => {
134
124
  * @param options
135
125
  */
136
126
  export const show = (type: ReportType, options: InvocationOption[]) => {
137
- console.log('[LCQ-RN] BugReporting.show called', { type, options });
138
127
  NativeBugReporting.show(type, options ?? []);
139
128
  };
140
129
 
@@ -143,7 +132,6 @@ export const show = (type: ReportType, options: InvocationOption[]) => {
143
132
  * @param isEnabled enable/disable screen recording on crash feature
144
133
  */
145
134
  export const setAutoScreenRecordingEnabled = (isEnabled: boolean) => {
146
- console.log('[LCQ-RN] BugReporting.setAutoScreenRecordingEnabled called', { isEnabled });
147
135
  NativeBugReporting.setAutoScreenRecordingEnabled(isEnabled);
148
136
  };
149
137
 
@@ -154,7 +142,6 @@ export const setAutoScreenRecordingEnabled = (isEnabled: boolean) => {
154
142
  * The maximum duration is 30 seconds
155
143
  */
156
144
  export const setAutoScreenRecordingDurationIOS = (maxDuration: number) => {
157
- console.log('[LCQ-RN] BugReporting.setAutoScreenRecordingDurationIOS called', { maxDuration });
158
145
  if (Platform.OS !== 'ios') {
159
146
  return;
160
147
  }
@@ -172,9 +159,6 @@ export const setAutoScreenRecordingDurationIOS = (maxDuration: number) => {
172
159
  export const setVideoRecordingFloatingButtonPosition = (
173
160
  buttonPosition: RecordingButtonPosition,
174
161
  ) => {
175
- console.log('[LCQ-RN] BugReporting.setVideoRecordingFloatingButtonPosition called', {
176
- buttonPosition,
177
- });
178
162
  NativeBugReporting.setVideoRecordingFloatingButtonPosition(buttonPosition);
179
163
  };
180
164
 
@@ -183,7 +167,6 @@ export const setVideoRecordingFloatingButtonPosition = (
183
167
  * @param isEnabled A boolean to set whether view hierarchy are enabled or disabled.
184
168
  */
185
169
  export const setViewHierarchyEnabled = (isEnabled: boolean) => {
186
- console.log('[LCQ-RN] BugReporting.setViewHierarchyEnabled called', { isEnabled });
187
170
  NativeBugReporting.setViewHierarchyEnabled(isEnabled);
188
171
  };
189
172
 
@@ -202,13 +185,6 @@ export const addUserConsent = (
202
185
  checked: boolean,
203
186
  actionType?: userConsentActionType,
204
187
  ) => {
205
- console.log('[LCQ-RN] BugReporting.addUserConsent called', {
206
- key,
207
- description,
208
- mandatory,
209
- checked,
210
- actionType,
211
- });
212
188
  NativeBugReporting.addUserConsent(key, description, mandatory, checked, actionType);
213
189
  };
214
190
  /**
@@ -216,7 +192,6 @@ export const addUserConsent = (
216
192
  * @param handler - A callback that gets executed when a prompt option is selected.
217
193
  */
218
194
  export const setDidSelectPromptOptionHandler = (handler: (promptOption: string) => void) => {
219
- console.log('[LCQ-RN] BugReporting.setDidSelectPromptOptionHandler called');
220
195
  if (Platform.OS === 'android') {
221
196
  return;
222
197
  }
@@ -233,7 +208,6 @@ export const setDidSelectPromptOptionHandler = (handler: (promptOption: string)
233
208
  * @param offset The offset of the floating button from the top of the screen. Default is 50.
234
209
  */
235
210
  export const setFloatingButtonEdge = (edge: FloatingButtonPosition, offset: number) => {
236
- console.log('[LCQ-RN] BugReporting.setFloatingButtonEdge called', { edge, offset });
237
211
  NativeBugReporting.setFloatingButtonEdge(edge, offset);
238
212
  };
239
213
 
@@ -251,12 +225,6 @@ export const setEnabledAttachmentTypes = (
251
225
  galleryImage: boolean,
252
226
  screenRecording: boolean,
253
227
  ) => {
254
- console.log('[LCQ-RN] BugReporting.setEnabledAttachmentTypes called', {
255
- screenshot,
256
- extraScreenshot,
257
- galleryImage,
258
- screenRecording,
259
- });
260
228
  NativeBugReporting.setEnabledAttachmentTypes(
261
229
  screenshot,
262
230
  extraScreenshot,
@@ -270,7 +238,6 @@ export const setEnabledAttachmentTypes = (
270
238
  * @param text String text.
271
239
  */
272
240
  export const setDisclaimerText = (text: string) => {
273
- console.log('[LCQ-RN] BugReporting.setDisclaimerText called', { text });
274
241
  NativeBugReporting.setDisclaimerText(text);
275
242
  };
276
243
 
@@ -281,10 +248,6 @@ export const setDisclaimerText = (text: string) => {
281
248
  * @platform iOS
282
249
  */
283
250
  export const setCommentMinimumCharacterCount = (limit: number, reportTypes?: ReportType[]) => {
284
- console.log('[LCQ-RN] BugReporting.setCommentMinimumCharacterCount called', {
285
- limit,
286
- reportTypes,
287
- });
288
251
  if (Platform.OS === 'ios') {
289
252
  NativeBugReporting.setCommentMinimumCharacterCount(limit, reportTypes ?? []);
290
253
  }
@@ -295,7 +258,6 @@ export const setCommentMinimumCharacterCount = (limit: number, reportTypes?: Rep
295
258
  * @param config configuration of proActive bug report.
296
259
  */
297
260
  export const setProactiveReportingConfigurations = (config: ProactiveReportingConfigOptions) => {
298
- console.log('[LCQ-RN] BugReporting.setProactiveReportingConfigurations called', { config });
299
261
  NativeBugReporting.setProactiveReportingConfigurations(
300
262
  config.enabled,
301
263
  config.gapBetweenModals,
@@ -13,7 +13,6 @@ import { Logger } from '../utils/logger';
13
13
  * @param isEnabled
14
14
  */
15
15
  export const setEnabled = (isEnabled: boolean) => {
16
- console.log('[LCQ-RN] CrashReporting.setEnabled called', { isEnabled });
17
16
  NativeCrashReporting.setEnabled(isEnabled);
18
17
  };
19
18
 
@@ -23,7 +22,6 @@ export const setEnabled = (isEnabled: boolean) => {
23
22
  * @param nonFatalOptions extra config for the non-fatal error sent with Error Object
24
23
  */
25
24
  export const reportError = (error: ExtendedError, nonFatalOptions: NonFatalOptions = {}) => {
26
- console.log('[LCQ-RN] CrashReporting.reportError called', { error, nonFatalOptions });
27
25
  if (error instanceof Error) {
28
26
  let level = NonFatalErrorLevel.error;
29
27
  if (nonFatalOptions.level != null) {
@@ -50,7 +48,6 @@ export const reportError = (error: ExtendedError, nonFatalOptions: NonFatalOptio
50
48
  * @param isEnabled
51
49
  */
52
50
  export const setNDKCrashesEnabled = (isEnabled: boolean) => {
53
- console.log('[LCQ-RN] CrashReporting.setNDKCrashesEnabled called', { isEnabled });
54
51
  if (Platform.OS === 'android') {
55
52
  NativeCrashReporting.setNDKCrashesEnabled(isEnabled);
56
53
  }
@@ -7,7 +7,6 @@ import type { ActionType } from '../utils/Enums';
7
7
  * @param isEnabled
8
8
  */
9
9
  export const setEnabled = (isEnabled: boolean) => {
10
- console.log('[LCQ-RN] FeatureRequests.setEnabled called', { isEnabled });
11
10
  NativeFeatureRequests.setEnabled(isEnabled);
12
11
  };
13
12
 
@@ -20,10 +19,6 @@ export const setEnabled = (isEnabled: boolean) => {
20
19
  * @param types An enum that indicates which action types will have the isEmailFieldRequired
21
20
  */
22
21
  export const setEmailFieldRequired = (isEmailFieldRequired: boolean, type: ActionType) => {
23
- console.log('[LCQ-RN] FeatureRequests.setEmailFieldRequired called', {
24
- isEmailFieldRequired,
25
- type,
26
- });
27
22
  NativeFeatureRequests.setEmailFieldRequiredForFeatureRequests(isEmailFieldRequired, [
28
23
  type,
29
24
  ] as ActionType[]);
@@ -33,6 +28,5 @@ export const setEmailFieldRequired = (isEmailFieldRequired: boolean, type: Actio
33
28
  * Shows the UI for feature requests list
34
29
  */
35
30
  export const show = () => {
36
- console.log('[LCQ-RN] FeatureRequests.show called');
37
31
  NativeFeatureRequests.show();
38
32
  };