react-native-acoustic-connect-beta 18.0.13 → 18.0.15

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 (98) hide show
  1. package/Examples/SampleUI/.detoxrc.js +83 -0
  2. package/Examples/SampleUI/ConnectConfig.json +2 -2
  3. package/Examples/SampleUI/android/app/build.gradle +3 -0
  4. package/Examples/SampleUI/android/app/src/main/java/com/sampleui/MainActivity.kt +0 -35
  5. package/Examples/SampleUI/android/settings.gradle +1 -1
  6. package/Examples/SampleUI/package.json +8 -6
  7. package/Examples/SampleUI/scripts/integration-test-android.sh +292 -0
  8. package/Examples/SampleUI/src/Examples/DialogExample.tsx +88 -2
  9. package/Examples/SampleUI/src/Examples/Dialogs/DialogTrackingTest.tsx +307 -0
  10. package/Examples/SampleUI/src/Examples/Dialogs/index.tsx +37 -0
  11. package/Examples/SampleUI/src/index.native.tsx +5 -5
  12. package/android/build.gradle +2 -2
  13. package/android/src/main/assets/ConnectAdvancedConfig.json +1 -1
  14. package/android/src/main/assets/TealeafAdvancedConfig.json +1 -1
  15. package/android/src/main/java/com/acousticconnectrn/HybridAcousticConnectRN.kt +787 -490
  16. package/ios/HybridAcousticConnectRN.swift +79 -4
  17. package/lib/commonjs/TLTRN.js +69 -0
  18. package/lib/commonjs/TLTRN.js.map +1 -1
  19. package/lib/commonjs/components/Connect.js +31 -29
  20. package/lib/commonjs/components/Connect.js.map +1 -1
  21. package/lib/commonjs/docs/DialogTracking.md +252 -0
  22. package/lib/commonjs/docs/NativeImplementation.md +176 -0
  23. package/lib/commonjs/examples/DialogTrackingExample.js +175 -0
  24. package/lib/commonjs/examples/DialogTrackingExample.js.map +1 -0
  25. package/lib/commonjs/examples/HOCDialogExample.js +296 -0
  26. package/lib/commonjs/examples/HOCDialogExample.js.map +1 -0
  27. package/lib/commonjs/index.js +28 -0
  28. package/lib/commonjs/index.js.map +1 -1
  29. package/lib/commonjs/utils/DialogDebugger.js +216 -0
  30. package/lib/commonjs/utils/DialogDebugger.js.map +1 -0
  31. package/lib/commonjs/utils/DialogListener.js +203 -0
  32. package/lib/commonjs/utils/DialogListener.js.map +1 -0
  33. package/lib/commonjs/utils/useDialogTracking.js +107 -0
  34. package/lib/commonjs/utils/useDialogTracking.js.map +1 -0
  35. package/lib/commonjs/utils/withAcousticAutoDialog.js +282 -0
  36. package/lib/commonjs/utils/withAcousticAutoDialog.js.map +1 -0
  37. package/lib/module/TLTRN.js +69 -0
  38. package/lib/module/TLTRN.js.map +1 -1
  39. package/lib/module/components/Connect.js +32 -31
  40. package/lib/module/components/Connect.js.map +1 -1
  41. package/lib/module/docs/DialogTracking.md +252 -0
  42. package/lib/module/docs/NativeImplementation.md +176 -0
  43. package/lib/module/examples/DialogTrackingExample.js +172 -0
  44. package/lib/module/examples/DialogTrackingExample.js.map +1 -0
  45. package/lib/module/examples/HOCDialogExample.js +292 -0
  46. package/lib/module/examples/HOCDialogExample.js.map +1 -0
  47. package/lib/module/index.js +5 -1
  48. package/lib/module/index.js.map +1 -1
  49. package/lib/module/utils/DialogDebugger.js +211 -0
  50. package/lib/module/utils/DialogDebugger.js.map +1 -0
  51. package/lib/module/utils/DialogListener.js +199 -0
  52. package/lib/module/utils/DialogListener.js.map +1 -0
  53. package/lib/module/utils/useDialogTracking.js +102 -0
  54. package/lib/module/utils/useDialogTracking.js.map +1 -0
  55. package/lib/module/utils/withAcousticAutoDialog.js +275 -0
  56. package/lib/module/utils/withAcousticAutoDialog.js.map +1 -0
  57. package/lib/typescript/src/TLTRN.d.ts +7 -0
  58. package/lib/typescript/src/TLTRN.d.ts.map +1 -1
  59. package/lib/typescript/src/components/Connect.d.ts +2 -2
  60. package/lib/typescript/src/components/Connect.d.ts.map +1 -1
  61. package/lib/typescript/src/examples/DialogTrackingExample.d.ts +17 -0
  62. package/lib/typescript/src/examples/DialogTrackingExample.d.ts.map +1 -0
  63. package/lib/typescript/src/examples/HOCDialogExample.d.ts +21 -0
  64. package/lib/typescript/src/examples/HOCDialogExample.d.ts.map +1 -0
  65. package/lib/typescript/src/index.d.ts +5 -1
  66. package/lib/typescript/src/index.d.ts.map +1 -1
  67. package/lib/typescript/src/specs/react-native-acoustic-connect.nitro.d.ts +4 -0
  68. package/lib/typescript/src/specs/react-native-acoustic-connect.nitro.d.ts.map +1 -1
  69. package/lib/typescript/src/utils/DialogDebugger.d.ts +58 -0
  70. package/lib/typescript/src/utils/DialogDebugger.d.ts.map +1 -0
  71. package/lib/typescript/src/utils/DialogListener.d.ts +85 -0
  72. package/lib/typescript/src/utils/DialogListener.d.ts.map +1 -0
  73. package/lib/typescript/src/utils/useDialogTracking.d.ts +25 -0
  74. package/lib/typescript/src/utils/useDialogTracking.d.ts.map +1 -0
  75. package/lib/typescript/src/utils/withAcousticAutoDialog.d.ts +37 -0
  76. package/lib/typescript/src/utils/withAcousticAutoDialog.d.ts.map +1 -0
  77. package/nitrogen/generated/android/c++/JHybridAcousticConnectRNSpec.cpp +26 -0
  78. package/nitrogen/generated/android/c++/JHybridAcousticConnectRNSpec.hpp +4 -0
  79. package/nitrogen/generated/android/kotlin/com/margelo/nitro/acousticconnectrn/HybridAcousticConnectRNSpec.kt +16 -0
  80. package/nitrogen/generated/ios/c++/HybridAcousticConnectRNSpecSwift.hpp +32 -0
  81. package/nitrogen/generated/ios/swift/HybridAcousticConnectRNSpec.swift +4 -0
  82. package/nitrogen/generated/ios/swift/HybridAcousticConnectRNSpec_cxx.swift +71 -0
  83. package/nitrogen/generated/shared/c++/HybridAcousticConnectRNSpec.cpp +4 -0
  84. package/nitrogen/generated/shared/c++/HybridAcousticConnectRNSpec.hpp +4 -0
  85. package/package.json +1 -1
  86. package/scripts/ConnectConfig.json +1 -1
  87. package/src/TLTRN.ts +75 -0
  88. package/src/components/Connect.tsx +92 -101
  89. package/src/docs/DialogTracking.md +252 -0
  90. package/src/docs/NativeImplementation.md +176 -0
  91. package/src/examples/DialogTrackingExample.tsx +163 -0
  92. package/src/examples/HOCDialogExample.tsx +253 -0
  93. package/src/index.ts +5 -1
  94. package/src/specs/react-native-acoustic-connect.nitro.ts +5 -0
  95. package/src/utils/DialogDebugger.ts +224 -0
  96. package/src/utils/DialogListener.ts +238 -0
  97. package/src/utils/useDialogTracking.ts +102 -0
  98. package/src/utils/withAcousticAutoDialog.tsx +312 -0
@@ -0,0 +1,17 @@
1
+ /********************************************************************************************
2
+ * Copyright (C) 2025 Acoustic, L.P. All rights reserved.
3
+ *
4
+ * NOTICE: This file contains material that is confidential and proprietary to
5
+ * Acoustic, L.P. and/or other developers. No license is granted under any intellectual or
6
+ * industrial property rights of Acoustic, L.P. except as may be provided in an agreement with
7
+ * Acoustic, L.P. Any unauthorized copying or distribution of content from this file is
8
+ * prohibited.
9
+ ********************************************************************************************/
10
+ import React from 'react';
11
+ /**
12
+ * Example component demonstrating dialog event tracking
13
+ * Shows how to use both automatic Alert.alert interception and manual custom dialog tracking
14
+ */
15
+ declare const DialogTrackingExample: React.FC;
16
+ export default DialogTrackingExample;
17
+ //# sourceMappingURL=DialogTrackingExample.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"DialogTrackingExample.d.ts","sourceRoot":"","sources":["../../../../src/examples/DialogTrackingExample.tsx"],"names":[],"mappings":"AAAA;;;;;;;;6FAQ6F;AAE7F,OAAO,KAAmB,MAAM,OAAO,CAAC;AAIxC;;;GAGG;AACH,QAAA,MAAM,qBAAqB,EAAE,KAAK,CAAC,EAkGlC,CAAC;AA8CF,eAAe,qBAAqB,CAAC"}
@@ -0,0 +1,21 @@
1
+ /********************************************************************************************
2
+ * Copyright (C) 2025 Acoustic, L.P. All rights reserved.
3
+ *
4
+ * NOTICE: This file contains material that is confidential and proprietary to
5
+ * Acoustic, L.P. and/or other developers. No license is granted under any intellectual or
6
+ * industrial property rights of Acoustic, L.P. except as may be provided in an agreement with
7
+ * Acoustic, L.P. Any unauthorized copying or distribution of content from this file is
8
+ * prohibited.
9
+ ********************************************************************************************/
10
+ import * as React from 'react';
11
+ /**
12
+ * Example demonstrating HOC-based Paper Dialog tracking
13
+ *
14
+ * This approach requires minimal code changes:
15
+ * 1. Create tracked versions of your dialog components
16
+ * 2. Use the tracked versions instead of the original ones
17
+ * 3. All dialog events are automatically tracked!
18
+ */
19
+ declare const HOCDialogExample: React.FC;
20
+ export default HOCDialogExample;
21
+ //# sourceMappingURL=HOCDialogExample.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"HOCDialogExample.d.ts","sourceRoot":"","sources":["../../../../src/examples/HOCDialogExample.tsx"],"names":[],"mappings":"AAAA;;;;;;;;6FAQ6F;AAE7F,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAI/B;;;;;;;GAOG;AACH,QAAA,MAAM,gBAAgB,EAAE,KAAK,CAAC,EA8F7B,CAAC;AAwIF,eAAe,gBAAgB,CAAC"}
@@ -13,8 +13,12 @@
13
13
  import type { AcousticConnectRN as AcousticConnectRNSpec } from './specs/react-native-acoustic-connect.nitro';
14
14
  import Connect from './components/Connect';
15
15
  import KeyboardListener from './utils/KeyboardListener';
16
+ import DialogListener from './utils/DialogListener';
17
+ import useDialogTracking from './utils/useDialogTracking';
18
+ import { withAcousticAutoDialog } from './utils/withAcousticAutoDialog';
19
+ import DialogDebugger from './utils/DialogDebugger';
16
20
  import TLTRN from './TLTRN';
17
21
  declare const AcousticConnectRN: AcousticConnectRNSpec;
18
- export { Connect, TLTRN, KeyboardListener };
22
+ export { Connect, TLTRN, KeyboardListener, DialogListener, useDialogTracking, DialogDebugger, withAcousticAutoDialog };
19
23
  export default AcousticConnectRN;
20
24
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;6FAW6F;AAG7F,OAAO,KAAK,EAAE,iBAAiB,IAAI,qBAAqB,EAAE,MAAM,6CAA6C,CAAA;AAC7G,OAAO,OAAO,MAAM,sBAAsB,CAAA;AAC1C,OAAO,gBAAgB,MAAM,0BAA0B,CAAA;AACvD,OAAO,KAAK,MAAM,SAAS,CAAA;AAE3B,QAAA,MAAM,iBAAiB,uBAA8E,CAAA;AAErG,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,gBAAgB,EAAC,CAAA;AAC1C,eAAe,iBAAiB,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;6FAW6F;AAG7F,OAAO,KAAK,EAAE,iBAAiB,IAAI,qBAAqB,EAAE,MAAM,6CAA6C,CAAA;AAC7G,OAAO,OAAO,MAAM,sBAAsB,CAAA;AAC1C,OAAO,gBAAgB,MAAM,0BAA0B,CAAA;AACvD,OAAO,cAAc,MAAM,wBAAwB,CAAA;AACnD,OAAO,iBAAiB,MAAM,2BAA2B,CAAA;AACzD,OAAO,EAAE,sBAAsB,EAAE,MAAM,gCAAgC,CAAA;AACvE,OAAO,cAAc,MAAM,wBAAwB,CAAA;AACnD,OAAO,KAAK,MAAM,SAAS,CAAA;AAE3B,QAAA,MAAM,iBAAiB,uBAA8E,CAAA;AAErG,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,gBAAgB,EAAE,cAAc,EAAE,iBAAiB,EAAE,cAAc,EAAE,sBAAsB,EAAE,CAAA;AACtH,eAAe,iBAAiB,CAAA"}
@@ -26,5 +26,9 @@ export interface AcousticConnectRN extends HybridObject<{
26
26
  logScreenViewContextLoad(logicalPageName: string | null | undefined, referrer: string | null | undefined): boolean;
27
27
  logScreenViewContextUnload(logicalPageName: string | null | undefined, referrer: string | null | undefined): boolean;
28
28
  logScreenLayout(name: string, delay: number): boolean;
29
+ logDialogShowEvent(dialogId: string, dialogTitle: string, dialogType: string): boolean;
30
+ logDialogDismissEvent(dialogId: string, dismissReason: string): boolean;
31
+ logDialogButtonClickEvent(dialogId: string, buttonText: string, buttonIndex: number): boolean;
32
+ logDialogCustomEvent(dialogId: string, eventName: string, values: Record<string, string | number | boolean>): boolean;
29
33
  }
30
34
  //# sourceMappingURL=react-native-acoustic-connect.nitro.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"react-native-acoustic-connect.nitro.d.ts","sourceRoot":"","sources":["../../../../src/specs/react-native-acoustic-connect.nitro.ts"],"names":[],"mappings":"AAYA,OAAO,EAAE,KAAK,YAAY,EAAE,MAAM,4BAA4B,CAAA;AAG9D,MAAM,MAAM,cAAc,GAAG;IACzB,WAAW,EAAE,MAAM,CAAC;IACpB,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC;CAC1B,CAAC;AAEF,MAAM,MAAM,0BAA0B,GAAG,QAAQ,GAAG,iBAAiB,GAAG,MAAM,CAAA;AAE9E,MAAM,WAAW,iBAAkB,SAAQ,YAAY,CAAC;IAAE,GAAG,EAAE,OAAO,CAAC;IAAC,OAAO,EAAE,QAAQ,CAAA;CAAE,CAAC;IACxF,0BAA0B,CAAC,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,OAAO,EAAE,UAAU,EAAE,MAAM,GAAG,OAAO,CAAA;IACpF,mBAAmB,CAAC,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,GAAG,OAAO,CAAA;IAC5E,mBAAmB,CAAC,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,GAAG,OAAO,CAAA;IAC5E,mBAAmB,CAAC,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,MAAM,GAAG,OAAO,EAAE,UAAU,EAAE,MAAM,GAAG,OAAO,CAAA;IAC/F,0BAA0B,CAAC,UAAU,EAAE,OAAO,EAAE,GAAG,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,GAAG,OAAO,CAAA;IACzF,mBAAmB,CAAC,UAAU,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,GAAI,MAAM,GAAG,IAAI,GAAG,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EAAE,WAAW,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,GAAG,OAAO,CAAA;IACtF,qBAAqB,CAAC,QAAQ,EAAE,MAAM,EAAE,aAAa,EAAE,MAAM,GAAG,OAAO,CAAA;IACvE,yBAAyB,CAAC,QAAQ,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,EAAE,WAAW,EAAE,MAAM,GAAG,OAAO,CAAA;IAC7F,oBAAoB,CAAC,QAAQ,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,GAAG,OAAO,CAAC,GAAG,OAAO,CAAA;CACxH"}
@@ -0,0 +1,58 @@
1
+ /********************************************************************************************
2
+ * Copyright (C) 2025 Acoustic, L.P. All rights reserved.
3
+ *
4
+ * NOTICE: This file contains material that is confidential and proprietary to
5
+ * Acoustic, L.P. and/or other developers. No license is granted under any intellectual or
6
+ * industrial property rights of Acoustic, L.P. except as may be provided in an agreement with
7
+ * Acoustic, L.P. Any unauthorized copying or distribution of content from this file is
8
+ * prohibited.
9
+ ********************************************************************************************/
10
+ /**
11
+ * Debug utility for dialog event tracking
12
+ * Helps identify issues with dialog event interception and logging
13
+ */
14
+ export declare class DialogDebugger {
15
+ private static instance;
16
+ private isEnabled;
17
+ private originalAlert;
18
+ private constructor();
19
+ static getInstance(): DialogDebugger;
20
+ /**
21
+ * Enable debug mode
22
+ */
23
+ enable(): void;
24
+ /**
25
+ * Disable debug mode
26
+ */
27
+ disable(): void;
28
+ /**
29
+ * Test the complete dialog event flow
30
+ */
31
+ testDialogEventFlow(): void;
32
+ /**
33
+ * Test DialogListener functionality
34
+ */
35
+ private testDialogListener;
36
+ /**
37
+ * Test TLTRN methods
38
+ */
39
+ private testTLTRNMethods;
40
+ /**
41
+ * Test Alert.alert override
42
+ */
43
+ private testAlertOverride;
44
+ /**
45
+ * Test native method calls
46
+ */
47
+ private testNativeMethods;
48
+ /**
49
+ * Check if dialog tracking is properly enabled
50
+ */
51
+ checkDialogTrackingStatus(): void;
52
+ /**
53
+ * Force enable dialog tracking for testing
54
+ */
55
+ forceEnableDialogTracking(): void;
56
+ }
57
+ export default DialogDebugger;
58
+ //# sourceMappingURL=DialogDebugger.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"DialogDebugger.d.ts","sourceRoot":"","sources":["../../../../src/utils/DialogDebugger.ts"],"names":[],"mappings":"AAAA;;;;;;;;6FAQ6F;AAM7F;;;GAGG;AACH,qBAAa,cAAc;IACvB,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAiB;IACxC,OAAO,CAAC,SAAS,CAAkB;IACnC,OAAO,CAAC,aAAa,CAAqB;IAE1C,OAAO;IAIP,MAAM,CAAC,WAAW,IAAI,cAAc;IAOpC;;OAEG;IACH,MAAM,IAAI,IAAI;IAKd;;OAEG;IACH,OAAO,IAAI,IAAI;IAKf;;OAEG;IACH,mBAAmB,IAAI,IAAI;IAgB3B;;OAEG;IACH,OAAO,CAAC,kBAAkB;IAuB1B;;OAEG;IACH,OAAO,CAAC,gBAAgB;IA0BxB;;OAEG;IACH,OAAO,CAAC,iBAAiB;IAsBzB;;OAEG;IACH,OAAO,CAAC,iBAAiB;IAsBzB;;OAEG;IACH,yBAAyB,IAAI,IAAI;IAwBjC;;OAEG;IACH,yBAAyB,IAAI,IAAI;CAiBpC;AAED,eAAe,cAAc,CAAC"}
@@ -0,0 +1,85 @@
1
+ /********************************************************************************************
2
+ * Copyright (C) 2025 Acoustic, L.P. All rights reserved.
3
+ *
4
+ * NOTICE: This file contains material that is confidential and proprietary to
5
+ * Acoustic, L.P. and/or other developers. No license is granted under any intellectual or
6
+ * industrial property rights of Acoustic, L.P. except as may be provided in an agreement with
7
+ * Acoustic, L.P. Any unauthorized copying or distribution of content from this file is
8
+ * prohibited.
9
+ ********************************************************************************************/
10
+ import type { AlertButton } from 'react-native';
11
+ export interface DialogEvent {
12
+ dialogId: string;
13
+ dialogTitle: string;
14
+ dialogType: 'alert' | 'custom' | 'modal';
15
+ timestamp: number;
16
+ buttons?: AlertButton[];
17
+ }
18
+ export interface DialogButtonClickEvent {
19
+ dialogId: string;
20
+ buttonText: string;
21
+ buttonIndex: number;
22
+ timestamp: number;
23
+ }
24
+ export interface DialogDismissEvent {
25
+ dialogId: string;
26
+ dialogTitle: string;
27
+ dialogType: 'alert' | 'custom' | 'modal';
28
+ dismissReason: string;
29
+ timestamp: number;
30
+ }
31
+ declare class DialogListener {
32
+ private static instance;
33
+ private activeDialogs;
34
+ private originalAlert;
35
+ private isIntercepting;
36
+ private eventCallbacks;
37
+ private constructor();
38
+ static getInstance(): DialogListener;
39
+ /**
40
+ * Start intercepting dialog events
41
+ */
42
+ startIntercepting(): void;
43
+ /**
44
+ * Stop intercepting dialog events
45
+ */
46
+ stopIntercepting(): void;
47
+ /**
48
+ * Add event callback for dialog events
49
+ */
50
+ addEventListener(callback: (event: DialogEvent | DialogButtonClickEvent | DialogDismissEvent) => void): () => void;
51
+ /**
52
+ * Intercept React Native's Alert.alert API
53
+ */
54
+ private interceptAlertAPI;
55
+ /**
56
+ * Manually track custom dialog show event
57
+ */
58
+ trackCustomDialogShow(dialogId: string, title: string, buttons?: AlertButton[]): void;
59
+ /**
60
+ * Manually track custom dialog dismiss event
61
+ */
62
+ trackCustomDialogDismiss(dialogId: string, reason?: string): void;
63
+ /**
64
+ * Manually track custom dialog button click event
65
+ */
66
+ trackCustomDialogButtonClick(dialogId: string, buttonText: string, buttonIndex: number): void;
67
+ /**
68
+ * Get currently active dialogs
69
+ */
70
+ getActiveDialogs(): DialogEvent[];
71
+ /**
72
+ * Clear all active dialogs
73
+ */
74
+ clearActiveDialogs(): void;
75
+ /**
76
+ * Emit event to all registered callbacks
77
+ */
78
+ private emitEvent;
79
+ /**
80
+ * Restore original Alert.alert API
81
+ */
82
+ restoreOriginalAlert(): void;
83
+ }
84
+ export default DialogListener;
85
+ //# sourceMappingURL=DialogListener.d.ts.map
@@ -0,0 +1 @@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iB;IAkDzB;;OAEG;IACH,qBAAqB,CAAC,QAAQ,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,WAAW,EAAE,GAAG,IAAI;IAerF;;OAEG;IACH,wBAAwB,CAAC,QAAQ,EAAE,MAAM,EAAE,MAAM,GAAE,MAAiB,GAAG,IAAI;IAqB3E;;OAEG;IACH,4BAA4B,CAAC,QAAQ,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,EAAE,WAAW,EAAE,MAAM,GAAG,IAAI;IAa7F;;OAEG;IACH,gBAAgB,IAAI,WAAW,EAAE;IAIjC;;OAEG;IACH,kBAAkB,IAAI,IAAI;IAI1B;;OAEG;IACH,OAAO,CAAC,SAAS;IAUjB;;OAEG;IACH,oBAAoB,IAAI,IAAI;CAG/B;AAED,eAAe,cAAc,CAAC"}
@@ -0,0 +1,25 @@
1
+ /********************************************************************************************
2
+ * Copyright (C) 2025 Acoustic, L.P. All rights reserved.
3
+ *
4
+ * NOTICE: This file contains material that is confidential and proprietary to
5
+ * Acoustic, L.P. and/or other developers. No license is granted under any intellectual or
6
+ * industrial property rights of Acoustic, L.P. except as may be provided in an agreement with
7
+ * Acoustic, L.P. Any unauthorized copying or distribution of content from this file is
8
+ * prohibited.
9
+ ********************************************************************************************/
10
+ import type { AlertButton } from 'react-native';
11
+ /**
12
+ * React hook for tracking custom dialog events
13
+ * Provides utilities to track dialog show, dismiss, and button click events
14
+ */
15
+ export declare const useDialogTracking: () => {
16
+ generateDialogId: () => string;
17
+ trackDialogShow: (dialogId: string, title: string, buttons?: AlertButton[]) => void;
18
+ trackDialogDismiss: (dialogId: string, reason?: string) => void;
19
+ trackDialogButtonClick: (dialogId: string, buttonText: string, buttonIndex: number) => void;
20
+ trackDialogCustomEvent: (dialogId: string, eventName: string, values: Record<string, string | number | boolean>) => void;
21
+ createTrackedButton: (dialogId: string, button: AlertButton, buttonIndex: number) => AlertButton;
22
+ cleanup: () => void;
23
+ };
24
+ export default useDialogTracking;
25
+ //# sourceMappingURL=useDialogTracking.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useDialogTracking.d.ts","sourceRoot":"","sources":["../../../../src/utils/useDialogTracking.ts"],"names":[],"mappings":"AAAA;;;;;;;;6FAQ6F;AAG7F,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAIhD;;;GAGG;AACH,eAAO,MAAM,iBAAiB;4BAMe,MAAM;gCASA,MAAM,SAAS,MAAM,YAAY,WAAW,EAAE;mCAS3C,MAAM,WAAU,MAAM;uCASlB,MAAM,cAAc,MAAM,eAAe,MAAM;uCAS/C,MAAM,aAAa,MAAM,UAAU,OAAO,MAAM,EAAE,MAAM,GAAG,MAAM,GAAG,OAAO,CAAC;oCAO/E,MAAM,UAAU,WAAW,eAAe,MAAM,KAAG,WAAW;;CA+BpH,CAAC;AAEF,eAAe,iBAAiB,CAAC"}
@@ -0,0 +1,37 @@
1
+ /********************************************************************************************
2
+ * Copyright (C) 2025 Acoustic, L.P. All rights reserved.
3
+ *
4
+ * NOTICE: This file contains material that is confidential and proprietary to
5
+ * Acoustic, L.P. and/or other developers. No license is granted under any intellectual or
6
+ * industrial property rights of Acoustic, L.P. except as may be provided in an agreement with
7
+ * Acoustic, L.P. Any unauthorized copying or distribution of content from this file is
8
+ * prohibited.
9
+ *
10
+ * Created by Omar Hernandez on 5/9/25.
11
+ *
12
+ ********************************************************************************************/
13
+ import React from 'react';
14
+ /**
15
+ * HOC Wrapper that automatically tracks dialog show/dismiss events and button clicks
16
+ * Works with any dialog component that has 'visible' and 'onDismiss' props
17
+ *
18
+ * Supported Dialog Patterns:
19
+ * - react-native-paper Dialog components
20
+ * - Custom modal components with visible/onDismiss props
21
+ * - Components with different prop names (show/hide, open/close, etc.)
22
+ * - Components with custom button implementations
23
+ * - Components with nested dialog structures
24
+ */
25
+ export declare function withAcousticAutoDialog(DialogComponent: React.ComponentType<any>): React.ComponentType<any>;
26
+ /**
27
+ * Convenience function to create tracked versions of common dialog components
28
+ */
29
+ export declare function createTrackedDialogComponents(): {};
30
+ /**
31
+ * Hook to get tracked dialog components
32
+ */
33
+ export declare function useTrackedDialogs(): {
34
+ withAcousticAutoDialog: typeof withAcousticAutoDialog;
35
+ createTrackedDialogComponents: typeof createTrackedDialogComponents;
36
+ };
37
+ //# sourceMappingURL=withAcousticAutoDialog.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"withAcousticAutoDialog.d.ts","sourceRoot":"","sources":["../../../../src/utils/withAcousticAutoDialog.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;6FAW6F;AAE7F,OAAO,KAA0E,MAAM,OAAO,CAAC;AAK/F;;;;;;;;;;GAUG;AACH,wBAAgB,sBAAsB,CACpC,eAAe,EAAE,KAAK,CAAC,aAAa,CAAC,GAAG,CAAC,GACxC,KAAK,CAAC,aAAa,CAAC,GAAG,CAAC,CAgQ1B;AAED;;GAEG;AACH,wBAAgB,6BAA6B,OAS5C;AAED;;GAEG;AACH,wBAAgB,iBAAiB;;;EAKhC"}
@@ -138,5 +138,31 @@ namespace margelo::nitro::acousticconnectrn {
138
138
  auto __result = method(_javaPart, jni::make_jstring(name), delay);
139
139
  return static_cast<bool>(__result);
140
140
  }
141
+ bool JHybridAcousticConnectRNSpec::logDialogShowEvent(const std::string& dialogId, const std::string& dialogTitle, const std::string& dialogType) {
142
+ static const auto method = javaClassStatic()->getMethod<jboolean(jni::alias_ref<jni::JString> /* dialogId */, jni::alias_ref<jni::JString> /* dialogTitle */, jni::alias_ref<jni::JString> /* dialogType */)>("logDialogShowEvent");
143
+ auto __result = method(_javaPart, jni::make_jstring(dialogId), jni::make_jstring(dialogTitle), jni::make_jstring(dialogType));
144
+ return static_cast<bool>(__result);
145
+ }
146
+ bool JHybridAcousticConnectRNSpec::logDialogDismissEvent(const std::string& dialogId, const std::string& dismissReason) {
147
+ static const auto method = javaClassStatic()->getMethod<jboolean(jni::alias_ref<jni::JString> /* dialogId */, jni::alias_ref<jni::JString> /* dismissReason */)>("logDialogDismissEvent");
148
+ auto __result = method(_javaPart, jni::make_jstring(dialogId), jni::make_jstring(dismissReason));
149
+ return static_cast<bool>(__result);
150
+ }
151
+ bool JHybridAcousticConnectRNSpec::logDialogButtonClickEvent(const std::string& dialogId, const std::string& buttonText, double buttonIndex) {
152
+ static const auto method = javaClassStatic()->getMethod<jboolean(jni::alias_ref<jni::JString> /* dialogId */, jni::alias_ref<jni::JString> /* buttonText */, double /* buttonIndex */)>("logDialogButtonClickEvent");
153
+ auto __result = method(_javaPart, jni::make_jstring(dialogId), jni::make_jstring(buttonText), buttonIndex);
154
+ return static_cast<bool>(__result);
155
+ }
156
+ bool JHybridAcousticConnectRNSpec::logDialogCustomEvent(const std::string& dialogId, const std::string& eventName, const std::unordered_map<std::string, std::variant<std::string, double, bool>>& values) {
157
+ static const auto method = javaClassStatic()->getMethod<jboolean(jni::alias_ref<jni::JString> /* dialogId */, jni::alias_ref<jni::JString> /* eventName */, jni::alias_ref<jni::JMap<jni::JString, JVariant_String_Double_Boolean>> /* values */)>("logDialogCustomEvent");
158
+ auto __result = method(_javaPart, jni::make_jstring(dialogId), jni::make_jstring(eventName), [&]() -> jni::local_ref<jni::JMap<jni::JString, JVariant_String_Double_Boolean>> {
159
+ auto __map = jni::JHashMap<jni::JString, JVariant_String_Double_Boolean>::create(values.size());
160
+ for (const auto& __entry : values) {
161
+ __map->put(jni::make_jstring(__entry.first), JVariant_String_Double_Boolean::fromCpp(__entry.second));
162
+ }
163
+ return __map;
164
+ }());
165
+ return static_cast<bool>(__result);
166
+ }
141
167
 
142
168
  } // namespace margelo::nitro::acousticconnectrn
@@ -69,6 +69,10 @@ namespace margelo::nitro::acousticconnectrn {
69
69
  bool logScreenViewContextLoad(const std::optional<std::string>& logicalPageName, const std::optional<std::string>& referrer) override;
70
70
  bool logScreenViewContextUnload(const std::optional<std::string>& logicalPageName, const std::optional<std::string>& referrer) override;
71
71
  bool logScreenLayout(const std::string& name, double delay) override;
72
+ bool logDialogShowEvent(const std::string& dialogId, const std::string& dialogTitle, const std::string& dialogType) override;
73
+ bool logDialogDismissEvent(const std::string& dialogId, const std::string& dismissReason) override;
74
+ bool logDialogButtonClickEvent(const std::string& dialogId, const std::string& buttonText, double buttonIndex) override;
75
+ bool logDialogCustomEvent(const std::string& dialogId, const std::string& eventName, const std::unordered_map<std::string, std::variant<std::string, double, bool>>& values) override;
72
76
 
73
77
  private:
74
78
  friend HybridBase;
@@ -111,6 +111,22 @@ abstract class HybridAcousticConnectRNSpec: HybridObject() {
111
111
  @DoNotStrip
112
112
  @Keep
113
113
  abstract fun logScreenLayout(name: String, delay: Double): Boolean
114
+
115
+ @DoNotStrip
116
+ @Keep
117
+ abstract fun logDialogShowEvent(dialogId: String, dialogTitle: String, dialogType: String): Boolean
118
+
119
+ @DoNotStrip
120
+ @Keep
121
+ abstract fun logDialogDismissEvent(dialogId: String, dismissReason: String): Boolean
122
+
123
+ @DoNotStrip
124
+ @Keep
125
+ abstract fun logDialogButtonClickEvent(dialogId: String, buttonText: String, buttonIndex: Double): Boolean
126
+
127
+ @DoNotStrip
128
+ @Keep
129
+ abstract fun logDialogCustomEvent(dialogId: String, eventName: String, values: Map<String, Variant_String_Double_Boolean>): Boolean
114
130
 
115
131
  private external fun initHybrid(): HybridData
116
132
 
@@ -202,6 +202,38 @@ namespace margelo::nitro::acousticconnectrn {
202
202
  auto __value = std::move(__result.value());
203
203
  return __value;
204
204
  }
205
+ inline bool logDialogShowEvent(const std::string& dialogId, const std::string& dialogTitle, const std::string& dialogType) override {
206
+ auto __result = _swiftPart.logDialogShowEvent(dialogId, dialogTitle, dialogType);
207
+ if (__result.hasError()) [[unlikely]] {
208
+ std::rethrow_exception(__result.error());
209
+ }
210
+ auto __value = std::move(__result.value());
211
+ return __value;
212
+ }
213
+ inline bool logDialogDismissEvent(const std::string& dialogId, const std::string& dismissReason) override {
214
+ auto __result = _swiftPart.logDialogDismissEvent(dialogId, dismissReason);
215
+ if (__result.hasError()) [[unlikely]] {
216
+ std::rethrow_exception(__result.error());
217
+ }
218
+ auto __value = std::move(__result.value());
219
+ return __value;
220
+ }
221
+ inline bool logDialogButtonClickEvent(const std::string& dialogId, const std::string& buttonText, double buttonIndex) override {
222
+ auto __result = _swiftPart.logDialogButtonClickEvent(dialogId, buttonText, std::forward<decltype(buttonIndex)>(buttonIndex));
223
+ if (__result.hasError()) [[unlikely]] {
224
+ std::rethrow_exception(__result.error());
225
+ }
226
+ auto __value = std::move(__result.value());
227
+ return __value;
228
+ }
229
+ inline bool logDialogCustomEvent(const std::string& dialogId, const std::string& eventName, const std::unordered_map<std::string, std::variant<std::string, double, bool>>& values) override {
230
+ auto __result = _swiftPart.logDialogCustomEvent(dialogId, eventName, values);
231
+ if (__result.hasError()) [[unlikely]] {
232
+ std::rethrow_exception(__result.error());
233
+ }
234
+ auto __value = std::move(__result.value());
235
+ return __value;
236
+ }
205
237
 
206
238
  private:
207
239
  AcousticConnectRN::HybridAcousticConnectRNSpec_cxx _swiftPart;
@@ -32,6 +32,10 @@ public protocol HybridAcousticConnectRNSpec_protocol: HybridObject {
32
32
  func logScreenViewContextLoad(logicalPageName: String?, referrer: String?) throws -> Bool
33
33
  func logScreenViewContextUnload(logicalPageName: String?, referrer: String?) throws -> Bool
34
34
  func logScreenLayout(name: String, delay: Double) throws -> Bool
35
+ func logDialogShowEvent(dialogId: String, dialogTitle: String, dialogType: String) throws -> Bool
36
+ func logDialogDismissEvent(dialogId: String, dismissReason: String) throws -> Bool
37
+ func logDialogButtonClickEvent(dialogId: String, buttonText: String, buttonIndex: Double) throws -> Bool
38
+ func logDialogCustomEvent(dialogId: String, eventName: String, values: Dictionary<String, Variant_String_Double_Bool>) throws -> Bool
35
39
  }
36
40
 
37
41
  /// See ``HybridAcousticConnectRNSpec``
@@ -412,4 +412,75 @@ public class HybridAcousticConnectRNSpec_cxx {
412
412
  return bridge.create_Result_bool_(__exceptionPtr)
413
413
  }
414
414
  }
415
+
416
+ @inline(__always)
417
+ public final func logDialogShowEvent(dialogId: std.string, dialogTitle: std.string, dialogType: std.string) -> bridge.Result_bool_ {
418
+ do {
419
+ let __result = try self.__implementation.logDialogShowEvent(dialogId: String(dialogId), dialogTitle: String(dialogTitle), dialogType: String(dialogType))
420
+ let __resultCpp = __result
421
+ return bridge.create_Result_bool_(__resultCpp)
422
+ } catch (let __error) {
423
+ let __exceptionPtr = __error.toCpp()
424
+ return bridge.create_Result_bool_(__exceptionPtr)
425
+ }
426
+ }
427
+
428
+ @inline(__always)
429
+ public final func logDialogDismissEvent(dialogId: std.string, dismissReason: std.string) -> bridge.Result_bool_ {
430
+ do {
431
+ let __result = try self.__implementation.logDialogDismissEvent(dialogId: String(dialogId), dismissReason: String(dismissReason))
432
+ let __resultCpp = __result
433
+ return bridge.create_Result_bool_(__resultCpp)
434
+ } catch (let __error) {
435
+ let __exceptionPtr = __error.toCpp()
436
+ return bridge.create_Result_bool_(__exceptionPtr)
437
+ }
438
+ }
439
+
440
+ @inline(__always)
441
+ public final func logDialogButtonClickEvent(dialogId: std.string, buttonText: std.string, buttonIndex: Double) -> bridge.Result_bool_ {
442
+ do {
443
+ let __result = try self.__implementation.logDialogButtonClickEvent(dialogId: String(dialogId), buttonText: String(buttonText), buttonIndex: buttonIndex)
444
+ let __resultCpp = __result
445
+ return bridge.create_Result_bool_(__resultCpp)
446
+ } catch (let __error) {
447
+ let __exceptionPtr = __error.toCpp()
448
+ return bridge.create_Result_bool_(__exceptionPtr)
449
+ }
450
+ }
451
+
452
+ @inline(__always)
453
+ public final func logDialogCustomEvent(dialogId: std.string, eventName: std.string, values: bridge.std__unordered_map_std__string__std__variant_std__string__double__bool__) -> bridge.Result_bool_ {
454
+ do {
455
+ let __result = try self.__implementation.logDialogCustomEvent(dialogId: String(dialogId), eventName: String(eventName), values: { () -> Dictionary<String, Variant_String_Double_Bool> in
456
+ var __dictionary = Dictionary<String, Variant_String_Double_Bool>(minimumCapacity: values.size())
457
+ let __keys = bridge.get_std__unordered_map_std__string__std__variant_std__string__double__bool___keys(values)
458
+ for __key in __keys {
459
+ let __value = values[__key]!
460
+ __dictionary[String(__key)] = { () -> Variant_String_Double_Bool in
461
+ let __variant = bridge.std__variant_std__string__double__bool_(__value)
462
+ switch __variant.index() {
463
+ case 0:
464
+ let __actual = __variant.get_0()
465
+ return .first(String(__actual))
466
+ case 1:
467
+ let __actual = __variant.get_1()
468
+ return .second(__actual)
469
+ case 2:
470
+ let __actual = __variant.get_2()
471
+ return .third(__actual)
472
+ default:
473
+ fatalError("Variant can never have index \(__variant.index())!")
474
+ }
475
+ }()
476
+ }
477
+ return __dictionary
478
+ }())
479
+ let __resultCpp = __result
480
+ return bridge.create_Result_bool_(__resultCpp)
481
+ } catch (let __error) {
482
+ let __exceptionPtr = __error.toCpp()
483
+ return bridge.create_Result_bool_(__exceptionPtr)
484
+ }
485
+ }
415
486
  }
@@ -32,6 +32,10 @@ namespace margelo::nitro::acousticconnectrn {
32
32
  prototype.registerHybridMethod("logScreenViewContextLoad", &HybridAcousticConnectRNSpec::logScreenViewContextLoad);
33
33
  prototype.registerHybridMethod("logScreenViewContextUnload", &HybridAcousticConnectRNSpec::logScreenViewContextUnload);
34
34
  prototype.registerHybridMethod("logScreenLayout", &HybridAcousticConnectRNSpec::logScreenLayout);
35
+ prototype.registerHybridMethod("logDialogShowEvent", &HybridAcousticConnectRNSpec::logDialogShowEvent);
36
+ prototype.registerHybridMethod("logDialogDismissEvent", &HybridAcousticConnectRNSpec::logDialogDismissEvent);
37
+ prototype.registerHybridMethod("logDialogButtonClickEvent", &HybridAcousticConnectRNSpec::logDialogButtonClickEvent);
38
+ prototype.registerHybridMethod("logDialogCustomEvent", &HybridAcousticConnectRNSpec::logDialogCustomEvent);
35
39
  });
36
40
  }
37
41
 
@@ -69,6 +69,10 @@ namespace margelo::nitro::acousticconnectrn {
69
69
  virtual bool logScreenViewContextLoad(const std::optional<std::string>& logicalPageName, const std::optional<std::string>& referrer) = 0;
70
70
  virtual bool logScreenViewContextUnload(const std::optional<std::string>& logicalPageName, const std::optional<std::string>& referrer) = 0;
71
71
  virtual bool logScreenLayout(const std::string& name, double delay) = 0;
72
+ virtual bool logDialogShowEvent(const std::string& dialogId, const std::string& dialogTitle, const std::string& dialogType) = 0;
73
+ virtual bool logDialogDismissEvent(const std::string& dialogId, const std::string& dismissReason) = 0;
74
+ virtual bool logDialogButtonClickEvent(const std::string& dialogId, const std::string& buttonText, double buttonIndex) = 0;
75
+ virtual bool logDialogCustomEvent(const std::string& dialogId, const std::string& eventName, const std::unordered_map<std::string, std::variant<std::string, double, bool>>& values) = 0;
72
76
 
73
77
  protected:
74
78
  // Hybrid Setup
package/package.json CHANGED
@@ -192,7 +192,7 @@
192
192
  "source": "src/index",
193
193
  "summary": "react-native ios android tealeaf connect cxa wxca er enhanced-replay",
194
194
  "types": "./lib/typescript/src/index.d.ts",
195
- "version": "18.0.13",
195
+ "version": "18.0.15",
196
196
  "workspaces": [
197
197
  "example"
198
198
  ]
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "Connect": {
3
- "AndroidVersion": "10.4.45",
3
+ "AndroidVersion": "10.4.61",
4
4
  "AppKey": "b6c3709b7a4c479bb4b5a9fb8fec324c",
5
5
  "KillSwitchUrl": "https://lib-us-2.brilliantcollector.com/collector/switch/b6c3709b7a4c479bb4b5a9fb8fec324c",
6
6
  "PostMessageUrl": "https://lib-us-2.brilliantcollector.com/collector/collectorPost",