react-native-acoustic-connect-beta 18.0.12 → 18.0.14

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 (48) hide show
  1. package/Examples/SampleUI/src/RootNavigator.tsx +1 -1
  2. package/Examples/SampleUI/src/index.native.tsx +47 -31
  3. package/android/src/main/assets/ConnectAdvancedConfig.json +1 -1
  4. package/android/src/main/assets/TealeafAdvancedConfig.json +1 -1
  5. package/ios/HybridAcousticConnectRN.swift +4 -4
  6. package/lib/commonjs/TLTRN.js +219 -0
  7. package/lib/commonjs/TLTRN.js.map +1 -0
  8. package/lib/commonjs/components/Connect.js +19 -14
  9. package/lib/commonjs/components/Connect.js.map +1 -1
  10. package/lib/commonjs/components/ConnectProfiler.js +45 -0
  11. package/lib/commonjs/components/ConnectProfiler.js.map +1 -0
  12. package/lib/commonjs/index.js +14 -3
  13. package/lib/commonjs/index.js.map +1 -1
  14. package/lib/commonjs/utils/KeyboardListener.js +110 -0
  15. package/lib/commonjs/utils/KeyboardListener.js.map +1 -0
  16. package/lib/module/TLTRN.js +214 -0
  17. package/lib/module/TLTRN.js.map +1 -0
  18. package/lib/module/components/Connect.js +18 -14
  19. package/lib/module/components/Connect.js.map +1 -1
  20. package/lib/module/components/ConnectProfiler.js +40 -0
  21. package/lib/module/components/ConnectProfiler.js.map +1 -0
  22. package/lib/module/index.js +4 -3
  23. package/lib/module/index.js.map +1 -1
  24. package/lib/module/utils/KeyboardListener.js +105 -0
  25. package/lib/module/utils/KeyboardListener.js.map +1 -0
  26. package/lib/typescript/src/TLTRN.d.ts +47 -0
  27. package/lib/typescript/src/TLTRN.d.ts.map +1 -0
  28. package/lib/typescript/src/components/Connect.d.ts.map +1 -1
  29. package/lib/typescript/src/components/ConnectProfiler.d.ts +23 -0
  30. package/lib/typescript/src/components/ConnectProfiler.d.ts.map +1 -0
  31. package/lib/typescript/src/index.d.ts +3 -1
  32. package/lib/typescript/src/index.d.ts.map +1 -1
  33. package/{jslib/components/ConnectProfiler.js → lib/typescript/src/utils/KeyboardListener.d.ts} +9 -29
  34. package/lib/typescript/src/utils/KeyboardListener.d.ts.map +1 -0
  35. package/package.json +1 -2
  36. package/scripts/ConnectConfig.json +1 -1
  37. package/{jslib/TLTRN.js → src/TLTRN.ts} +54 -39
  38. package/src/components/Connect.tsx +18 -16
  39. package/src/components/ConnectProfiler.ts +43 -0
  40. package/src/index.ts +4 -2
  41. package/src/utils/KeyboardListener.ts +113 -0
  42. package/jslib/utils/KeyboardListener.js +0 -100
  43. package/lib/typescript/jslib/TLTRN.d.ts +0 -37
  44. package/lib/typescript/jslib/TLTRN.d.ts.map +0 -1
  45. package/lib/typescript/jslib/components/ConnectProfiler.d.ts +0 -10
  46. package/lib/typescript/jslib/components/ConnectProfiler.d.ts.map +0 -1
  47. package/lib/typescript/jslib/utils/KeyboardListener.d.ts +0 -10
  48. package/lib/typescript/jslib/utils/KeyboardListener.d.ts.map +0 -1
@@ -15,7 +15,7 @@ import ExampleList, { examples } from './ExampleList';
15
15
  // Log all exported items from the module
16
16
  import AcousticConnectRN from 'react-native-acoustic-connect-beta';
17
17
  import * as AcousticConnectBeta from 'react-native-acoustic-connect-beta';
18
- console.log('Exported items from react-native-acoustic-connect-beta:', AcousticConnectBeta);
18
+ console.log('RootNavigator.tsx:Exported items from react-native-acoustic-connect-beta:', AcousticConnectBeta);
19
19
 
20
20
  const result = AcousticConnectRN.logCustomEvent('test', {test: 'test'}, 1);
21
21
  console.log('result', result);
@@ -32,6 +32,12 @@ import DrawerItems from './DrawerItems';
32
32
  import App from './RootNavigator';
33
33
  import { deviceColorsSupported } from '../utils';
34
34
 
35
+ import * as AcousticConnectBeta from 'react-native-acoustic-connect-beta';
36
+ console.log('index.native.tsx:Exported items from react-native-acoustic-connect-beta:', AcousticConnectBeta);
37
+ import { NavigationContainerRef } from '@react-navigation/native';
38
+ import { useRef } from 'react';
39
+
40
+
35
41
  const PERSISTENCE_KEY = 'NAVIGATION_STATE';
36
42
  const PREFERENCES_KEY = 'APP_PREFERENCES';
37
43
 
@@ -58,6 +64,9 @@ const Drawer = createDrawerNavigator<{ Home: undefined }>();
58
64
  export default function PaperExample() {
59
65
  useKeepAwake();
60
66
 
67
+ // Add for Acoustic Connect SDK
68
+ const navigationRef = useRef<NavigationContainerRef>(null);
69
+
61
70
  const [fontsLoaded] = useFonts({
62
71
  Abel: require('../assets/fonts/Abel-Regular.ttf'),
63
72
  });
@@ -232,37 +241,44 @@ export default function PaperExample() {
232
241
  >
233
242
  <PreferencesContext.Provider value={preferences}>
234
243
  <React.Fragment>
235
- <NavigationContainer
236
- theme={combinedTheme}
237
- initialState={initialState}
238
- onStateChange={(state) =>
239
- AsyncStorage.setItem(PERSISTENCE_KEY, JSON.stringify(state))
240
- }
241
- >
242
- <SafeAreaInsetsContext.Consumer>
243
- {(insets) => {
244
- const { left, right } = insets || { left: 0, right: 0 };
245
- const collapsedDrawerWidth = 80 + Math.max(left, right);
246
- return (
247
- <Drawer.Navigator
248
- screenOptions={{
249
- drawerStyle: collapsed && {
250
- width: collapsedDrawerWidth,
251
- },
252
- }}
253
- drawerContent={() => <DrawerItems />}
254
- >
255
- <Drawer.Screen
256
- name="Home"
257
- component={App}
258
- options={{ headerShown: false }}
259
- />
260
- </Drawer.Navigator>
261
- );
262
- }}
263
- </SafeAreaInsetsContext.Consumer>
264
- <StatusBar style={!theme.isV3 || theme.dark ? 'light' : 'dark'} />
265
- </NavigationContainer>
244
+ <AcousticConnectBeta.Connect
245
+ captureKeyboardEvents={true}
246
+ navigationRef={navigationRef} // Pass the ref to Connect
247
+ >
248
+ <NavigationContainer
249
+ ref={navigationRef} // Pass the same ref to NavigationContainer
250
+ theme={combinedTheme}
251
+ initialState={initialState}
252
+ onStateChange={(state) =>
253
+ AsyncStorage.setItem(PERSISTENCE_KEY, JSON.stringify(state))
254
+ }
255
+ onReady={() => console.log('NavigationContainer is ready!')}
256
+ >
257
+ <SafeAreaInsetsContext.Consumer>
258
+ {(insets) => {
259
+ const { left, right } = insets || { left: 0, right: 0 };
260
+ const collapsedDrawerWidth = 80 + Math.max(left, right);
261
+ return (
262
+ <Drawer.Navigator
263
+ screenOptions={{
264
+ drawerStyle: collapsed && {
265
+ width: collapsedDrawerWidth,
266
+ },
267
+ }}
268
+ drawerContent={() => <DrawerItems />}
269
+ >
270
+ <Drawer.Screen
271
+ name="Home"
272
+ component={App}
273
+ options={{ headerShown: false }}
274
+ />
275
+ </Drawer.Navigator>
276
+ );
277
+ }}
278
+ </SafeAreaInsetsContext.Consumer>
279
+ <StatusBar style={!theme.isV3 || theme.dark ? 'light' : 'dark'} />
280
+ </NavigationContainer>
281
+ </AcousticConnectBeta.Connect>
266
282
  </React.Fragment>
267
283
  </PreferencesContext.Provider>
268
284
  </PaperProvider>
@@ -24,7 +24,7 @@
24
24
  "IpPlaceholder": "N/A",
25
25
  "KillSwitchAsync": true,
26
26
  "KillSwitchDelay": 300,
27
- "LibraryVersion": "10.4.37",
27
+ "LibraryVersion": "10.4.59",
28
28
  "LogFullRequestResponsePayloads": true,
29
29
  "MessageTypeHeader": "WorklightHit",
30
30
  "MessageTypes": "4,5",
@@ -24,7 +24,7 @@
24
24
  "IpPlaceholder": "N/A",
25
25
  "KillSwitchAsync": true,
26
26
  "KillSwitchDelay": 300,
27
- "LibraryVersion": "10.4.12",
27
+ "LibraryVersion": "10.4.16",
28
28
  "LogFullRequestResponsePayloads": true,
29
29
  "MessageTypeHeader": "WorklightHit",
30
30
  "MessageTypes": "4,5",
@@ -37,10 +37,10 @@ class HybridAcousticConnectRN: HybridAcousticConnectRNSpec {
37
37
  func load() {
38
38
  DispatchQueue.main.async {
39
39
  self.loadConnectConfig()
40
- EOApplicationHelper().setConfigItem(kConfigurableItemSetGestureDetector, value: "false", forModuleName: kTLFCoreModule)
41
- EOApplicationHelper().setConfigItem(kConfigurableItemLogViewLayoutOnScreenTransition, value: "false", forModuleName: kTLFCoreModule)
40
+ // EOApplicationHelper().setConfigItem(kConfigurableItemSetGestureDetector, value: "false", forModuleName: kTLFCoreModule)
41
+ // EOApplicationHelper().setConfigItem(kConfigurableItemLogViewLayoutOnScreenTransition, value: "false", forModuleName: kTLFCoreModule)
42
+ ConnectApplicationHelper().isReactNative(true, wrapNavigationContainer: true)
42
43
  ConnectApplicationHelper().enableFramework()
43
- ConnectApplicationHelper().isReactNative(true)
44
44
  }
45
45
  }
46
46
 
@@ -280,7 +280,7 @@ class HybridAcousticConnectRN: HybridAcousticConnectRNSpec {
280
280
  /// - Parameter logicalPageName: Page name or title e.g. "Login View Controller"; Must not be empty.
281
281
  /// - Returns: Boolean value will return whether it was able to log the screenview event.
282
282
  func setCurrentScreenName(logicalPageName: String) throws -> Bool {
283
- let result = ConnectApplicationHelper().resume(logicalPageName)
283
+ let result = ConnectApplicationHelper().setCurrentScreenName(logicalPageName)
284
284
  return result
285
285
  }
286
286
 
@@ -0,0 +1,219 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.default = void 0;
7
+ var _MessageQueue = _interopRequireDefault(require("react-native/Libraries/BatchedBridge/MessageQueue.js"));
8
+ var _reactNative = require("react-native");
9
+ var _KeyboardListener = _interopRequireDefault(require("./utils/KeyboardListener"));
10
+ var _index = _interopRequireDefault(require("./index"));
11
+ function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
12
+ /********************************************************************************************
13
+ * Copyright (C) 2025 Acoustic, L.P. All rights reserved.
14
+ *
15
+ * NOTICE: This file contains material that is confidential and proprietary to
16
+ * Acoustic, L.P. and/or other developers. No license is granted under any intellectual or
17
+ * industrial property rights of Acoustic, L.P. except as may be provided in an agreement with
18
+ * Acoustic, L.P. Any unauthorized copying or distribution of content from this file is
19
+ * prohibited.
20
+ ********************************************************************************************/
21
+
22
+ // @ts-ignore
23
+
24
+ // @ts-ignore
25
+ global.ErrorUtils.setGlobalHandler((e, _isFatal) => {
26
+ _index.default.logExceptionEvent(JSON.stringify(e), JSON.stringify(e), true);
27
+ });
28
+ class TLTRN {
29
+ static currentScreen = "***initialCurrentScreen not set in ConnectLogger constructor***";
30
+ static lastJSBridgeMessageTime = 0;
31
+ static totalRenderTime = 0;
32
+ static messageRenderTime = 0;
33
+ static countMsgs = 0;
34
+ static messageConsole = 0;
35
+ static lastMessageConsole = 0;
36
+ static isLoggingData = 0;
37
+ static displayDebug = false;
38
+ static myTimer = {
39
+ handle: null,
40
+ started: 0,
41
+ time: 1000,
42
+ /**
43
+ * @type Class
44
+ */
45
+ startTimer: function () {
46
+ this.started = 1;
47
+ this.handle = setInterval(TLTRN.checkTime, this.time);
48
+ },
49
+ /**
50
+ * @type Class
51
+ */
52
+ stopTimer: function () {
53
+ if (this.handle) {
54
+ clearInterval(this.handle);
55
+ this.handle = null;
56
+ this.started = 0;
57
+ }
58
+ }
59
+ };
60
+ static init = (initialCurrentScreen, showDebugConsoleMessages) => {
61
+ TLTRN.currentScreen = initialCurrentScreen === undefined
62
+ // @ts-ignore:
63
+ ? currentScreenMsg : initialCurrentScreen;
64
+ _MessageQueue.default.spy(TLTRN.listenToBridge);
65
+ TLTRN.displayDebug = showDebugConsoleMessages === undefined ? false : showDebugConsoleMessages;
66
+ };
67
+ static interceptKeyboardEvents = enable => {
68
+ keyListener.interceptKeyboardEvents(enable);
69
+ };
70
+ static logScreenViewPageName = name => {
71
+ let result = false;
72
+ try {
73
+ result = _index.default.setCurrentScreenName(name || '');
74
+ } catch (error) {
75
+ console.log('LogScreenViewPageName error: ', error.message);
76
+ }
77
+ return result;
78
+ };
79
+ static logScreenViewContextLoad = (name, prevName) => {
80
+ let result = false;
81
+ try {
82
+ result = _index.default.logScreenViewContextLoad(name, prevName);
83
+ } catch (error) {
84
+ console.log('LogScreenViewContextLoad error: ', error.message);
85
+ }
86
+ return result;
87
+ };
88
+ static logScreenLayout = name => {
89
+ TLTRN.currentScreen = name || '';
90
+ let result = false;
91
+ try {
92
+ result = _index.default.logScreenLayout(TLTRN.currentScreen, 0);
93
+ } catch (error) {
94
+ console.log('LogScreenLayout error: ', error.message);
95
+ }
96
+ return result;
97
+ };
98
+ static logClickEvent = async event => {
99
+ let result = false;
100
+ if (!event.target || !event.target._nativeTag || typeof event.target._nativeTag === 'undefined') {
101
+ return result;
102
+ }
103
+ const events = event._dispatchInstances.filter(node => {
104
+ return node.memoizedProps && node.memoizedProps.id;
105
+ });
106
+ const id = events.length ? events[0].memoizedProps.id : '';
107
+ let target = event.target._nativeTag;
108
+ let controlId = event._targetInst.memoizedProps.id !== undefined ? event._targetInst.memoizedProps.id : id;
109
+ let ariaLabel = event._targetInst.memoizedProps.accessible !== undefined ? event._targetInst.memoizedProps.accessibilityLabel : '';
110
+ try {
111
+ if (_reactNative.Platform.OS === 'ios') {
112
+ result = _index.default.logClickEvent(target, controlId);
113
+ } else if (_reactNative.Platform.OS === 'android') {
114
+ result = _index.default.logClickEvent(target, controlId);
115
+ }
116
+ } catch (error) {
117
+ console.log('LogClickEvent error: ', error.message);
118
+ }
119
+ return result;
120
+ };
121
+ static logTextChangeEvent = async (target, controlId, text, _ariaLabel) => {
122
+ let result = false;
123
+ try {
124
+ if (_reactNative.Platform.OS === 'ios') {
125
+ result = _index.default.logTextChangeEvent(target, controlId, text);
126
+ } else if (_reactNative.Platform.OS === 'android') {
127
+ _index.default.logTextChangeEvent(target, controlId, text);
128
+ }
129
+ } catch (error) {
130
+ console.log('LogTextChangeEvent error: ', error.message);
131
+ }
132
+ return result;
133
+ };
134
+ static logCustomEvent = async (eventName, values, level) => {
135
+ let result = false;
136
+ try {
137
+ result = _index.default.logCustomEvent(eventName, values, level);
138
+ } catch (error) {
139
+ console.log('LogCustomEvent error: ', error.message);
140
+ }
141
+ return result;
142
+ };
143
+ static listenToBridge = message => {
144
+ if (TLTRN.displayDebug) {
145
+ console.log("&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&:isLoggingData:" + TLTRN.isLoggingData);
146
+ }
147
+ if (TLTRN.isLoggingData == 1) {
148
+ return;
149
+ }
150
+ var now = new Date().getTime();
151
+ if (TLTRN.lastJSBridgeMessageTime === 0) {
152
+ TLTRN.lastJSBridgeMessageTime = now;
153
+ }
154
+ if (TLTRN.messageConsole > 0) {
155
+ TLTRN.lastMessageConsole = TLTRN.messageConsole;
156
+ }
157
+ TLTRN.messageConsole = now;
158
+ TLTRN.countMsgs++;
159
+ if (TLTRN.myTimer.started === 0) {
160
+ TLTRN.myTimer.startTimer();
161
+ }
162
+ TLTRN.messageRenderTime = now - TLTRN.lastJSBridgeMessageTime;
163
+ TLTRN.totalRenderTime = TLTRN.totalRenderTime + TLTRN.messageRenderTime;
164
+ if (TLTRN.displayDebug) {
165
+ console.log("*after:countMsgs: " + TLTRN.countMsgs + ":tTotal:" + TLTRN.totalRenderTime + ":messageDuration:" + TLTRN.messageRenderTime);
166
+ }
167
+ TLTRN.lastJSBridgeMessageTime = now;
168
+ const from = message.type === 0 ? "N->JS" : "JS->N";
169
+ const data = from + " : " + message.module + "." + message.method + "(" + JSON.stringify(message.args) + ")";
170
+ if (TLTRN.displayDebug) {
171
+ if (message.module !== "UIManager") {
172
+ console.log("Message", message);
173
+ }
174
+ console.log("Message data:", data);
175
+ }
176
+ if (message.module === "ExceptionsManager") {
177
+ _index.default.logExceptionEvent(message.args[0], JSON.stringify(message.args[1]), true);
178
+ }
179
+ };
180
+ static checkTime = () => {
181
+ var now = new Date().getTime();
182
+ if (TLTRN.displayDebug) {
183
+ console.log("======>Done compare total:" + TLTRN.totalRenderTime + " :lastMessageConsole:" + TLTRN.lastMessageConsole + ":now:" + now + ":diff:" + (now - TLTRN.lastMessageConsole) + ":" + (now - TLTRN.lastMessageConsole > 50));
184
+ }
185
+ if (TLTRN.lastMessageConsole == 0) {
186
+ return;
187
+ }
188
+ if (now - TLTRN.lastMessageConsole > 20) {
189
+ if (TLTRN.displayDebug) {
190
+ console.log("======>Done capture:" + new Date().getTime());
191
+ }
192
+ TLTRN.messageConsole = 0;
193
+ TLTRN.lastMessageConsole = 0;
194
+ TLTRN.myTimer.stopTimer();
195
+ this.logTeal();
196
+ }
197
+ };
198
+ static logTeal = async () => {
199
+ try {
200
+ TLTRN.isLoggingData = 1;
201
+ var res = await _index.default.logScreenLayout(TLTRN.currentScreen, -1);
202
+ var dict = {
203
+ ReactLayoutTime: TLTRN.totalRenderTime
204
+ };
205
+ var result = await _index.default.logCustomEvent("ReactPlugin", dict, 1);
206
+ if (TLTRN.displayDebug) {
207
+ console.log("======>logTeal:" + TLTRN.currentScreen + ":" + res + ":time:" + TLTRN.totalRenderTime);
208
+ }
209
+ TLTRN.isLoggingData = 0;
210
+ TLTRN.lastJSBridgeMessageTime = 0;
211
+ TLTRN.totalRenderTime = 0;
212
+ } catch (e) {
213
+ console.error(e);
214
+ }
215
+ };
216
+ }
217
+ const keyListener = _KeyboardListener.default._instance(TLTRN);
218
+ var _default = exports.default = TLTRN;
219
+ //# sourceMappingURL=TLTRN.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["_MessageQueue","_interopRequireDefault","require","_reactNative","_KeyboardListener","_index","e","__esModule","default","global","ErrorUtils","setGlobalHandler","_isFatal","AcousticConnectRN","logExceptionEvent","JSON","stringify","TLTRN","currentScreen","lastJSBridgeMessageTime","totalRenderTime","messageRenderTime","countMsgs","messageConsole","lastMessageConsole","isLoggingData","displayDebug","myTimer","handle","started","time","startTimer","setInterval","checkTime","stopTimer","clearInterval","init","initialCurrentScreen","showDebugConsoleMessages","undefined","currentScreenMsg","MessageQueue","spy","listenToBridge","interceptKeyboardEvents","enable","keyListener","logScreenViewPageName","name","result","setCurrentScreenName","error","console","log","message","logScreenViewContextLoad","prevName","logScreenLayout","logClickEvent","event","target","_nativeTag","events","_dispatchInstances","filter","node","memoizedProps","id","length","controlId","_targetInst","ariaLabel","accessible","accessibilityLabel","Platform","OS","logTextChangeEvent","text","_ariaLabel","logCustomEvent","eventName","values","level","now","Date","getTime","from","type","data","module","method","args","logTeal","res","dict","ReactLayoutTime","KeyboardListener","_inst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AAgB,CAACC,SAAS,CAAChF,KAAK,CAAC;AAAC,IAAAiF,QAAA,GAAAC,OAAA,CAAA3F,OAAA,GAEvCS,KAAK","ignoreList":[]}
@@ -6,7 +6,9 @@ Object.defineProperty(exports, "__esModule", {
6
6
  exports.default = void 0;
7
7
  var _react = _interopRequireWildcard(require("react"));
8
8
  var _reactNative = require("react-native");
9
+ var _TLTRN = _interopRequireDefault(require("../TLTRN"));
9
10
  var _jsxRuntime = require("react/jsx-runtime");
11
+ function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
10
12
  function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function (e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != typeof e && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (const t in e) "default" !== t && {}.hasOwnProperty.call(e, t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, t)) && (i.get || i.set) ? o(f, t, i) : f[t] = e[t]); return f; })(e, t); }
11
13
  /********************************************************************************************
12
14
  * Copyright (C) 2025 Acoustic, L.P. All rights reserved.
@@ -19,7 +21,6 @@ function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r
19
21
  ********************************************************************************************/
20
22
 
21
23
  // Use type-only import for LayoutChangeEvent
22
- // import TLTRN from '../TLTRN';
23
24
 
24
25
  const Connect = ({
25
26
  children,
@@ -29,33 +30,37 @@ const Connect = ({
29
30
  const currentRoute = (0, _react.useRef)(undefined);
30
31
  const initial = (0, _react.useRef)(false);
31
32
  (0, _react.useEffect)(() => {
32
- // TLTRN.interceptKeyboardEvents(captureKeyboardEvents);
33
+ _TLTRN.default.interceptKeyboardEvents(captureKeyboardEvents);
33
34
  }, [captureKeyboardEvents]);
34
35
  (0, _react.useEffect)(() => {
35
36
  if (!navigation || typeof navigation.current.addListener !== "function" || typeof navigation.current.getCurrentRoute !== "function") {
36
37
  console.warn("Connect: The Connect component's first child must be a NavigationContainer with a ref.");
37
38
  return;
38
39
  }
39
- const unsubscribe = navigation.current.addListener("state", () => {
40
+
41
+ // Listen for the 'state' event to track navigation state changes
42
+ const unsubscribeState = navigation.current.addListener("state", () => {
40
43
  currentRoute.current = extractName(navigation) || navigation.current.getCurrentRoute()?.name;
41
44
  console.log("State change - ", currentRoute.current);
42
45
  if (_reactNative.Platform.OS === "ios" && currentRoute && currentRoute.current) {
43
- // TLTRN.setCurrentScreenName(currentRoute.current);
46
+ _TLTRN.default.logScreenViewPageName(currentRoute.current);
44
47
  } else if (_reactNative.Platform.OS === "android") {
45
- // TLTRN.setCurrentScreenName(currentRoute.current);
46
- // TLTRN.logScreenLayout(currentRoute.current);
48
+ _TLTRN.default.logScreenViewPageName(currentRoute.current);
49
+ _TLTRN.default.logScreenLayout(currentRoute.current);
47
50
  }
48
51
  });
49
- return unsubscribe;
52
+
53
+ // Cleanup listeners when the component unmounts or dependencies change
54
+ return () => {
55
+ unsubscribeState();
56
+ };
50
57
  }, [navigation]);
51
58
  const onStartShouldSetResponderCapture = (0, _react.useCallback)(event => {
52
59
  currentRoute.current = extractName(navigation) || navigation.current.getCurrentRoute()?.name;
53
60
  if (currentRoute && currentRoute.current) {
54
- // TLTRN.setCurrentScreenName(currentRoute.current);
61
+ _TLTRN.default.logScreenViewPageName(currentRoute.current);
55
62
  }
56
- // Log the click event
57
- console.log("event - ", event.nativeEvent);
58
- // TLTRN.logClickEvent(event);
63
+ _TLTRN.default.logClickEvent(event);
59
64
  return false; // Must be false; true means this component becomes the touch responder and events don't bubble
60
65
  }, []);
61
66
  const onLayout = (0, _react.useCallback)(event => {
@@ -66,9 +71,9 @@ const Connect = ({
66
71
  console.log("event - ", event.nativeEvent);
67
72
  currentRoute.current = navigation.current.getCurrentRoute()?.name;
68
73
  if (_reactNative.Platform.OS === "ios" && currentRoute && currentRoute.current) {
69
- // TLTRN.setCurrentScreenName(currentRoute.current);
74
+ _TLTRN.default.logScreenViewPageName(currentRoute.current);
70
75
  } else if (_reactNative.Platform.OS === "android") {
71
- // TLTRN.logScreenLayout(currentRoute.current);
76
+ _TLTRN.default.logScreenLayout(currentRoute.current);
72
77
  }
73
78
  return true;
74
79
  }, [navigation]);
@@ -85,7 +90,7 @@ function extractName(navigation) {
85
90
  const {
86
91
  name
87
92
  } = routeParams;
88
- return name || "";
93
+ return name ? name : navigation.current?.getCurrentRoute()?.name || "";
89
94
  }
90
95
  return "";
91
96
  }
@@ -1 +1 @@
1
- {"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_jsxRuntime","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","Connect","children","captureKeyboardEvents","navigation","ref","currentRoute","useRef","undefined","initial","useEffect","current","addListener","getCurrentRoute","console","warn","unsubscribe","extractName","name","log","Platform","OS","onStartShouldSetResponderCapture","useCallback","event","nativeEvent","onLayout","jsx","View","style","styles","connect_main","routeParams","params","_default","exports","StyleSheet","create","flex"],"sourceRoot":"../../../src","sources":["components/Connect.tsx"],"mappings":";;;;;;AASA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AAAyF,IAAAE,WAAA,GAAAF,OAAA;AAAA,SAAAD,wBAAAI,CAAA,EAAAC,CAAA,6BAAAC,OAAA,MAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAN,uBAAA,YAAAA,CAAAI,CAAA,EAAAC,CAAA,SAAAA,CAAA,IAAAD,CAAA,IAAAA,CAAA,CAAAK,UAAA,SAAAL,CAAA,MAAAM,CAAA,EAAAC,CAAA,EAAAC,CAAA,KAAAC,SAAA,QAAAC,OAAA,EAAAV,CAAA,iBAAAA,CAAA,uBAAAA,CAAA,yBAAAA,CAAA,SAAAQ,CAAA,MAAAF,CAAA,GAAAL,CAAA,GAAAG,CA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AAIf,YAAY,IAAIA,YAAY,CAACK,OAAO,EAAE;MAC/D;IAAA,CACH,MAAM,IAAIS,qBAAQ,CAACC,EAAE,KAAK,SAAS,EAAE;MAClC;IAAA;IAEJ,OAAO,IAAI;EACf,CAAC,EAAE,CAACjB,UAAU,CAAC,CAAC;EAEhB,oBACI,IAAAvB,WAAA,CAAA8C,GAAA,EAAC/C,YAAA,CAAAgD,IAAI;IACDC,KAAK,EAAEC,MAAM,CAACC,YAAa;IAC3BL,QAAQ,EAAEA,QAAS;IACnBJ,gCAAgC,EAAEA,gCAAiC;IAAApB,QAAA,EAElEA;EAAQ,CACP,CAAC;AAEf,CAAC;AAED,SAASe,WAAWA,CAACb,UAAe,EAAU;EAC1C,MAAM4B,WAAW,GAAG5B,UAAU,CAACO,OAAO,CAACE,eAAe,CAAC,CAAC,EAAEoB,MAAM;EAChE,IAAID,WAAW,EAAE;IACb,MAAM;MAAEd;IAAK,CAAC,GAAGc,WAAW;IAC5B,OAAOd,IAAI,IAAI,EAAE;EACrB;EACA,OAAO,EAAE;AACb;AAAC,IAAAgB,QAAA,GAAAC,OAAA,CAAA3C,OAAA,GAEcS,OAAO;AAEtB,MAAM6B,MAAM,GAAGM,uBAAU,CAACC,MAAM,CAAC;EAC7BN,YAAY,EAAE;IACVO,IAAI,EAAE;EACV;AACJ,CAAC,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_TLTRN","_interopRequireDefault","_jsxRuntime","e","__esModule","default","t","WeakMap","r","n","o","i","f","__proto__","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","Connect","children","captureKeyboardEvents","navigation","ref","currentRoute","useRef","undefined","initial","useEffect","TLTRN","interceptKeyboardEvents","current","addListener","getCurrentRoute","console","warn","unsubscribeState","extractName","name","log","Platform","OS","logScreenViewPageName","logScreenLayout","onStartShouldSetResponderCapture","useCallback","event","logClickEvent","onLayout","nativeEvent","jsx","View","style","styles","connect_main","routeParams","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IACA,OAAO,IAAI;EACf,CAAC,EAAE,CAACT,UAAU,CAAC,CAAC;EAEhB,oBACI,IAAAvB,WAAA,CAAAmD,GAAA,EAACtD,YAAA,CAAAuD,IAAI;IACDC,KAAK,EAAEC,MAAM,CAACC,YAAa;IAC3BN,QAAQ,EAAEA,QAAS;IACnBJ,gCAAgC,EAAEA,gCAAiC;IAAAxB,QAAA,EAElEA;EAAQ,CACP,CAAC;AAEf,CAAC;AAED,SAASiB,WAAWA,CAACf,UAAe,EAAU;EAC1C,MAAMiC,WAAW,GAAGjC,UAAU,CAACS,OAAO,CAACE,eAAe,CAAC,CAAC,EAAEuB,MAAM;EAChE,IAAID,WAAW,EAAE;IACb,MAAM;MAAEjB;IAAK,CAAC,GAAGiB,WAAW;IAC5B,OAAOjB,IAAI,GAAGA,IAAI,GAAGhB,UAAU,CAACS,OAAO,EAAEE,eAAe,CAAC,CAAC,EAAEK,IAAI,IAAI,EAAE;EAC1E;EACA,OAAO,EAAE;AACb;AAAC,IAAAmB,QAAA,GAAAC,OAAA,CAAAxD,OAAA,GAEciB,OAAO;AAEtB,MAAMkC,MAAM,GAAGM,uBAAU,CAACC,MAAM,CAAC;EAC7BN,YAAY,EAAE;IACVO,IAAI,EAAE;EACV;AACJ,CAAC,CAAC","ignoreList":[]}
@@ -0,0 +1,45 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.default = void 0;
7
+ var _react = require("react");
8
+ var _TLTRN = _interopRequireDefault(require("../TLTRN"));
9
+ function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
10
+ /********************************************************************************************
11
+ * Copyright (C) 2025 Acoustic, L.P. All rights reserved.
12
+ *
13
+ * NOTICE: This file contains material that is confidential and proprietary to
14
+ * Acoustic, L.P. and/or other developers. No license is granted under any intellectual or
15
+ * industrial property rights of Acoustic, L.P. except as may be provided in an agreement with
16
+ * Acoustic, L.P. Any unauthorized copying or distribution of content from this file is
17
+ * prohibited.
18
+ ********************************************************************************************/
19
+
20
+ class ConnectProfiler extends _react.Component {
21
+ startTime = 0;
22
+ endTime = 0;
23
+ constructor(props) {
24
+ super(props);
25
+ this.startTime = new Date().getTime();
26
+ }
27
+ componentDidMount() {
28
+ this.endTime = new Date().getTime();
29
+ const pageLoadTime = this.endTime - this.startTime;
30
+ const {
31
+ profileName
32
+ } = this.props;
33
+ if (profileName) {
34
+ _TLTRN.default.logCustomEvent("Load Time", {
35
+ profileName,
36
+ pageLoadTime
37
+ }, 1);
38
+ }
39
+ }
40
+ render() {
41
+ return this.props.children;
42
+ }
43
+ }
44
+ var _default = exports.default = ConnectProfiler;
45
+ //# sourceMappingURL=ConnectProfiler.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["_react","require","_TLTRN","_interopRequireDefault","e","__esModule","default","ConnectProfiler","Component","startTime","endTime","constructor","props","Date","getTime","componentDidMount","pageLoadTime","profileName","TLTRN","logCustomEvent","render","children","_default","exports"],"sourceRoot":"../../../src","sources":["components/ConnectProfiler.ts"],"mappings":";;;;;;AAUA,IAAAA,MAAA,GAAAC,OAAA;AACA,IAAAC,MAAA,GAAAC,sBAAA,CAAAF,OAAA;AAA6B,SAAAE,uBAAAC,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;AAX7B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAUA,MAAMG,eAAe,SAASC,gBAAS,CAAuB;EAC5DC,SAAS,GAAG,CAAC;EACbC,OAAO,GAAG,CAAC;EAEXC,WAAWA,CAACC,KAA2B,EAAE;IACvC,KAAK,CAACA,KAAK,CAAC;IACZ,IAAI,CAACH,SAAS,GAAG,IAAII,IAAI,CAAC,CAAC,CAACC,OAAO,CAAC,CAAC;EACvC;EAEAC,iBAAiBA,CAAA,EAAG;IAClB,IAAI,CAACL,OAAO,GAAG,IAAIG,IAAI,CAAC,CAAC,CAACC,OAAO,CAAC,CAAC;IACnC,MAAME,YAAY,GAAG,IAAI,CAACN,OAAO,GAAG,IAAI,CAACD,SAAS;IAClD,MAAM;MAAEQ;IAAY,CAAC,GAAG,IAAI,CAACL,KAAK;IAElC,IAAIK,WAAW,EAAE;MACfC,cAAK,CAACC,cAAc,CAAC,WAAW,EAAE;QAAEF,WAAW;QAAED;MAAa,CAAC,EAAE,CAAC,CAAC;IACrE;EACF;EAEAI,MAAMA,CAAA,EAAG;IACP,OAAO,IAAI,CAACR,KAAK,CAACS,QAAQ;EAC5B;AACF;AAAC,IAAAC,QAAA,GAAAC,OAAA,CAAAjB,OAAA,GAEcC,eAAe","ignoreList":[]}
@@ -9,9 +9,23 @@ Object.defineProperty(exports, "Connect", {
9
9
  return _Connect.default;
10
10
  }
11
11
  });
12
+ Object.defineProperty(exports, "KeyboardListener", {
13
+ enumerable: true,
14
+ get: function () {
15
+ return _KeyboardListener.default;
16
+ }
17
+ });
18
+ Object.defineProperty(exports, "TLTRN", {
19
+ enumerable: true,
20
+ get: function () {
21
+ return _TLTRN.default;
22
+ }
23
+ });
12
24
  exports.default = void 0;
13
25
  var _reactNativeNitroModules = require("react-native-nitro-modules");
14
26
  var _Connect = _interopRequireDefault(require("./components/Connect"));
27
+ var _KeyboardListener = _interopRequireDefault(require("./utils/KeyboardListener"));
28
+ var _TLTRN = _interopRequireDefault(require("./TLTRN"));
15
29
  function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
16
30
  /********************************************************************************************
17
31
  * Copyright (C) 2025 Acoustic, L.P. All rights reserved.
@@ -26,9 +40,6 @@ function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e
26
40
  *
27
41
  ********************************************************************************************/
28
42
 
29
- // Import Connect.tsx
30
-
31
43
  const AcousticConnectRN = _reactNativeNitroModules.NitroModules.createHybridObject('AcousticConnectRN');
32
- // Export Connect.tsx
33
44
  var _default = exports.default = AcousticConnectRN;
34
45
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["_reactNativeNitroModules","require","_Connect","_interopRequireDefault","e","__esModule","default","AcousticConnectRN","NitroModules","createHybridObject","_default","exports"],"sourceRoot":"../../src","sources":["index.ts"],"mappings":";;;;;;;;;;;;AAaA,IAAAA,wBAAA,GAAAC,OAAA;AAEA,IAAAC,QAAA,GAAAC,sBAAA,CAAAF,OAAA;AAA0C,SAAAE,uBAAAC,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;AAf1C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAI2C;;AAE3C,MAAMG,iBAAiB,GAAGC,qCAAY,CAACC,kBAAkB,CAAwB,mBAAmB,CAAC;AAElF;AAAA,IAAAC,QAAA,GAAAC,OAAA,CAAAL,OAAA,GACJC,iBAAiB","ignoreList":[]}
1
+ {"version":3,"names":["_reactNativeNitroModules","require","_Connect","_interopRequireDefault","_KeyboardListener","_TLTRN","e","__esModule","default","AcousticConnectRN","NitroModules","createHybridObject","_default","exports"],"sourceRoot":"../../src","sources":["index.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;AAaA,IAAAA,wBAAA,GAAAC,OAAA;AAEA,IAAAC,QAAA,GAAAC,sBAAA,CAAAF,OAAA;AACA,IAAAG,iBAAA,GAAAD,sBAAA,CAAAF,OAAA;AACA,IAAAI,MAAA,GAAAF,sBAAA,CAAAF,OAAA;AAA2B,SAAAE,uBAAAG,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;AAjB3B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAQA,MAAMG,iBAAiB,GAAGC,qCAAY,CAACC,kBAAkB,CAAwB,mBAAmB,CAAC;AAAA,IAAAC,QAAA,GAAAC,OAAA,CAAAL,OAAA,GAGtFC,iBAAiB","ignoreList":[]}