react-native-inapp-inspector 2.3.14 → 2.3.16

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 (125) hide show
  1. package/README.md +1 -0
  2. package/dist/commonjs/components/AnimatedEntrance.js +3 -3
  3. package/dist/commonjs/components/ConsoleLogCard.js +174 -100
  4. package/dist/commonjs/components/Inspector/AnalyticsTab.js +0 -22
  5. package/dist/commonjs/components/Inspector/ConsoleTab.js +25 -38
  6. package/dist/commonjs/components/Inspector/CrashTab.js +19 -28
  7. package/dist/commonjs/components/Inspector/DeviceInfoTab.js +198 -98
  8. package/dist/commonjs/components/Inspector/FeedbackModal.d.ts +7 -0
  9. package/dist/commonjs/components/Inspector/FeedbackModal.js +552 -0
  10. package/dist/commonjs/components/Inspector/InspectorHeader.js +58 -6
  11. package/dist/commonjs/components/Inspector/MainScreen.js +100 -58
  12. package/dist/commonjs/components/Inspector/NetworkTab.js +26 -371
  13. package/dist/commonjs/components/Inspector/NpmStarPrompt.d.ts +3 -0
  14. package/dist/commonjs/components/Inspector/NpmStarPrompt.js +494 -0
  15. package/dist/commonjs/components/Inspector/PerformanceTab.js +40 -7
  16. package/dist/commonjs/components/Inspector/ReduxTab.js +3 -23
  17. package/dist/commonjs/components/Inspector/SettingsPanel.js +1035 -173
  18. package/dist/commonjs/components/Inspector/StorageTab.js +23 -28
  19. package/dist/commonjs/components/Inspector/TabBar.js +50 -15
  20. package/dist/commonjs/components/JsonViewer.js +14 -2
  21. package/dist/commonjs/components/LogCard.js +428 -227
  22. package/dist/commonjs/components/NetworkIcons.d.ts +5 -0
  23. package/dist/commonjs/components/NetworkIcons.js +33 -2
  24. package/dist/commonjs/constants/version.d.ts +1 -1
  25. package/dist/commonjs/constants/version.js +1 -1
  26. package/dist/commonjs/customHooks/analyticsLogger.js +1 -1
  27. package/dist/commonjs/customHooks/consoleLogger.js +34 -2
  28. package/dist/commonjs/customHooks/crashHandler.js +1 -1
  29. package/dist/commonjs/customHooks/networkLogger.js +184 -26
  30. package/dist/commonjs/helpers/index.d.ts +1 -0
  31. package/dist/commonjs/helpers/index.js +1 -0
  32. package/dist/commonjs/helpers/remoteConfig.d.ts +4 -0
  33. package/dist/commonjs/helpers/remoteConfig.js +165 -0
  34. package/dist/commonjs/helpers/searchQueryParser.d.ts +1 -1
  35. package/dist/commonjs/helpers/searchQueryParser.js +39 -291
  36. package/dist/commonjs/helpers/telemetry.d.ts +5 -0
  37. package/dist/commonjs/helpers/telemetry.js +339 -8
  38. package/dist/commonjs/index.d.ts +1 -0
  39. package/dist/commonjs/index.js +173 -29
  40. package/dist/commonjs/styles/AppFonts.d.ts +2 -0
  41. package/dist/commonjs/styles/AppFonts.js +1 -0
  42. package/dist/commonjs/styles/index.d.ts +22 -0
  43. package/dist/commonjs/styles/index.js +19 -0
  44. package/dist/commonjs/types/enums.d.ts +1 -0
  45. package/dist/commonjs/types/enums.js +1 -0
  46. package/dist/commonjs/types/interfaces.d.ts +12 -0
  47. package/dist/esm/components/AnimatedEntrance.js +3 -3
  48. package/dist/esm/components/ConsoleLogCard.js +141 -100
  49. package/dist/esm/components/Inspector/AnalyticsTab.js +1 -23
  50. package/dist/esm/components/Inspector/ConsoleTab.js +26 -39
  51. package/dist/esm/components/Inspector/CrashTab.js +20 -29
  52. package/dist/esm/components/Inspector/DeviceInfoTab.js +198 -98
  53. package/dist/esm/components/Inspector/FeedbackModal.d.ts +7 -0
  54. package/dist/esm/components/Inspector/FeedbackModal.js +515 -0
  55. package/dist/esm/components/Inspector/InspectorHeader.js +60 -8
  56. package/dist/esm/components/Inspector/MainScreen.js +101 -59
  57. package/dist/esm/components/Inspector/NetworkTab.js +27 -372
  58. package/dist/esm/components/Inspector/NpmStarPrompt.d.ts +3 -0
  59. package/dist/esm/components/Inspector/NpmStarPrompt.js +454 -0
  60. package/dist/esm/components/Inspector/PerformanceTab.js +40 -7
  61. package/dist/esm/components/Inspector/ReduxTab.js +4 -24
  62. package/dist/esm/components/Inspector/SettingsPanel.js +1038 -176
  63. package/dist/esm/components/Inspector/StorageTab.js +23 -28
  64. package/dist/esm/components/Inspector/TabBar.js +50 -15
  65. package/dist/esm/components/JsonViewer.js +14 -2
  66. package/dist/esm/components/LogCard.js +422 -221
  67. package/dist/esm/components/NetworkIcons.d.ts +5 -0
  68. package/dist/esm/components/NetworkIcons.js +26 -0
  69. package/dist/esm/constants/version.d.ts +1 -1
  70. package/dist/esm/constants/version.js +1 -1
  71. package/dist/esm/customHooks/analyticsLogger.js +1 -1
  72. package/dist/esm/customHooks/consoleLogger.js +34 -2
  73. package/dist/esm/customHooks/crashHandler.js +1 -1
  74. package/dist/esm/customHooks/networkLogger.js +184 -26
  75. package/dist/esm/helpers/index.d.ts +1 -0
  76. package/dist/esm/helpers/index.js +1 -0
  77. package/dist/esm/helpers/remoteConfig.d.ts +4 -0
  78. package/dist/esm/helpers/remoteConfig.js +160 -0
  79. package/dist/esm/helpers/searchQueryParser.d.ts +1 -1
  80. package/dist/esm/helpers/searchQueryParser.js +39 -291
  81. package/dist/esm/helpers/telemetry.d.ts +5 -0
  82. package/dist/esm/helpers/telemetry.js +332 -9
  83. package/dist/esm/index.d.ts +1 -0
  84. package/dist/esm/index.js +171 -29
  85. package/dist/esm/styles/AppFonts.d.ts +2 -0
  86. package/dist/esm/styles/AppFonts.js +1 -0
  87. package/dist/esm/styles/index.d.ts +22 -0
  88. package/dist/esm/styles/index.js +19 -0
  89. package/dist/esm/types/enums.d.ts +1 -0
  90. package/dist/esm/types/enums.js +1 -0
  91. package/dist/esm/types/interfaces.d.ts +12 -0
  92. package/package.json +1 -1
  93. package/src/components/AnimatedEntrance.tsx +3 -3
  94. package/src/components/ConsoleLogCard.tsx +154 -103
  95. package/src/components/Inspector/AnalyticsTab.tsx +0 -23
  96. package/src/components/Inspector/ConsoleTab.tsx +27 -41
  97. package/src/components/Inspector/CrashTab.tsx +19 -28
  98. package/src/components/Inspector/DeviceInfoTab.tsx +224 -102
  99. package/src/components/Inspector/FeedbackModal.tsx +626 -0
  100. package/src/components/Inspector/InspectorHeader.tsx +83 -5
  101. package/src/components/Inspector/MainScreen.tsx +61 -6
  102. package/src/components/Inspector/NetworkTab.tsx +70 -480
  103. package/src/components/Inspector/NpmStarPrompt.tsx +532 -0
  104. package/src/components/Inspector/PerformanceTab.tsx +44 -8
  105. package/src/components/Inspector/ReduxTab.tsx +9 -24
  106. package/src/components/Inspector/SettingsPanel.tsx +1162 -197
  107. package/src/components/Inspector/StorageTab.tsx +27 -30
  108. package/src/components/Inspector/TabBar.tsx +57 -20
  109. package/src/components/JsonViewer.tsx +15 -2
  110. package/src/components/LogCard.tsx +528 -339
  111. package/src/components/NetworkIcons.tsx +92 -0
  112. package/src/constants/version.ts +1 -1
  113. package/src/customHooks/analyticsLogger.ts +1 -1
  114. package/src/customHooks/consoleLogger.ts +36 -3
  115. package/src/customHooks/crashHandler.ts +1 -1
  116. package/src/customHooks/networkLogger.ts +214 -26
  117. package/src/helpers/index.ts +1 -0
  118. package/src/helpers/remoteConfig.ts +212 -0
  119. package/src/helpers/searchQueryParser.ts +42 -284
  120. package/src/helpers/telemetry.ts +381 -10
  121. package/src/index.tsx +374 -211
  122. package/src/styles/AppFonts.ts +2 -0
  123. package/src/styles/index.ts +20 -1
  124. package/src/types/enums.ts +1 -0
  125. package/src/types/interfaces.ts +12 -0
@@ -7,6 +7,7 @@ import {
7
7
  Pressable,
8
8
  ScrollView,
9
9
  Text,
10
+ TouchableOpacity,
10
11
  useWindowDimensions,
11
12
  View,
12
13
  } from 'react-native';
@@ -41,6 +42,7 @@ import {
41
42
  NpmIcon,
42
43
  ResetIcon,
43
44
  BoltIcon,
45
+ InfoCircleIcon,
44
46
  } from '../NetworkIcons';
45
47
 
46
48
  const InspectorHeader = React.memo(() => {
@@ -69,6 +71,9 @@ const InspectorHeader = React.memo(() => {
69
71
  runClearAllWithAnimation,
70
72
  settingsPage,
71
73
  setSettingsPage,
74
+ setSettingsActiveSubTab,
75
+ isFeedbackOpen,
76
+ setIsFeedbackOpen,
72
77
  resetToDefaults,
73
78
  closeModal,
74
79
  detailTitle,
@@ -146,7 +151,7 @@ const InspectorHeader = React.memo(() => {
146
151
  (activeTab === 'crash' && selectedCrash != null);
147
152
 
148
153
  const isSettingsView = settingsPage !== null;
149
- const isAnySelected = isDetailView || isSettingsView;
154
+ const isAnySelected = isDetailView || isSettingsView || isFeedbackOpen;
150
155
 
151
156
  const settingsModuleTitle = useMemo(() => {
152
157
  switch (settingsPage) {
@@ -205,6 +210,10 @@ const InspectorHeader = React.memo(() => {
205
210
  ]}>
206
211
  <TouchableScale
207
212
  onPress={() => {
213
+ if (isFeedbackOpen) {
214
+ setIsFeedbackOpen(false);
215
+ return;
216
+ }
208
217
  if (isSettingsView) {
209
218
  if (settingsPage === 'main') {
210
219
  setSettingsPage(null);
@@ -248,7 +257,50 @@ const InspectorHeader = React.memo(() => {
248
257
  <WhiteBackNavigation />
249
258
  </TouchableScale>
250
259
 
251
- {isSettingsView ? (
260
+ {isFeedbackOpen ? (
261
+ <View style={{gap: 2, flex: 1, minWidth: 0}}>
262
+ <View
263
+ style={{flexDirection: 'row', alignItems: 'center', gap: 6}}>
264
+ <Text
265
+ style={{
266
+ fontFamily: AppFonts.interBold,
267
+ fontSize: isNarrow ? 14 : 16,
268
+ color: AppColors.white,
269
+ letterSpacing: -0.2,
270
+ }}
271
+ numberOfLines={1}>
272
+ Support & Feedback
273
+ </Text>
274
+ <View
275
+ style={{
276
+ backgroundColor: `${AppColors.white}26`,
277
+ paddingHorizontal: isNarrow ? 4 : 6,
278
+ paddingVertical: 1.5,
279
+ borderRadius: 10,
280
+ borderWidth: 1,
281
+ borderColor: `${AppColors.white}20`,
282
+ }}>
283
+ <Text
284
+ style={{
285
+ fontFamily: AppFonts.interBold,
286
+ fontSize: isNarrow ? 8 : 9,
287
+ color: AppColors.white,
288
+ }}>
289
+ v{LIB_VERSION}
290
+ </Text>
291
+ </View>
292
+ </View>
293
+ <Text
294
+ style={{
295
+ fontFamily: AppFonts.interRegular,
296
+ fontSize: isNarrow ? 9.5 : 10.5,
297
+ color: `${AppColors.white}CC`,
298
+ }}
299
+ numberOfLines={1}>
300
+ Direct line to maintainers & developers
301
+ </Text>
302
+ </View>
303
+ ) : isSettingsView ? (
252
304
  <View style={{gap: 2, flex: 1, minWidth: 0}}>
253
305
  <View
254
306
  style={{flexDirection: 'row', alignItems: 'center', gap: 6}}>
@@ -996,6 +1048,9 @@ const InspectorHeader = React.memo(() => {
996
1048
 
997
1049
  {!isAnySelected && (
998
1050
  <TouchableScale
1051
+ accessible={true}
1052
+ accessibilityRole="button"
1053
+ accessibilityLabel="Settings"
999
1054
  onPress={() => setSettingsPage('main')}
1000
1055
  hitSlop={15}
1001
1056
  style={[
@@ -1010,9 +1065,32 @@ const InspectorHeader = React.memo(() => {
1010
1065
  </TouchableScale>
1011
1066
  )}
1012
1067
 
1013
- <TouchableScale
1068
+ {!isAnySelected && (
1069
+ <TouchableScale
1070
+ accessible={true}
1071
+ accessibilityRole="button"
1072
+ accessibilityLabel="About and System Specifications"
1073
+ onPress={() => {
1074
+ setSettingsActiveSubTab('about');
1075
+ setSettingsPage('main');
1076
+ }}
1077
+ hitSlop={15}
1078
+ style={[
1079
+ styles.closeButtonSquare,
1080
+ {
1081
+ width: buttonSize,
1082
+ height: buttonSize,
1083
+ borderRadius: isNarrow ? 6 : 7,
1084
+ },
1085
+ ]}>
1086
+ <InfoCircleIcon color={AppColors.white} size={isNarrow ? 12 : 14} />
1087
+ </TouchableScale>
1088
+ )}
1089
+
1090
+ <TouchableOpacity
1014
1091
  onPress={closeModal}
1015
- hitSlop={15}
1092
+ hitSlop={{top: 12, bottom: 12, left: 12, right: 12}}
1093
+ activeOpacity={0.6}
1016
1094
  style={[
1017
1095
  styles.closeButtonSquare,
1018
1096
  {
@@ -1022,7 +1100,7 @@ const InspectorHeader = React.memo(() => {
1022
1100
  },
1023
1101
  ]}>
1024
1102
  <CloseWhite size={isNarrow ? 12 : 14} />
1025
- </TouchableScale>
1103
+ </TouchableOpacity>
1026
1104
  </View>
1027
1105
  </View>
1028
1106
  </View>
@@ -8,6 +8,7 @@ import {
8
8
  StatusBar,
9
9
  StyleSheet,
10
10
  Text,
11
+ TouchableOpacity,
11
12
  View,
12
13
  } from 'react-native';
13
14
  import {useInspector} from './InspectorContext';
@@ -32,7 +33,11 @@ import StorageTab from './StorageTab';
32
33
  import DebuggingTab from './DebuggingTab';
33
34
  import SettingsPanel from './SettingsPanel';
34
35
  import NpmUpdateToast from './NpmUpdateToast';
36
+ import NpmStarPrompt from './NpmStarPrompt';
37
+ import FeedbackModal from './FeedbackModal';
35
38
  import Toast from '../Toast';
39
+ import TouchableScale from '../TouchableScale';
40
+ import {HeadphonesIcon} from '../NetworkIcons';
36
41
  import styles from '../../styles';
37
42
  import {AppColors} from '../../styles/AppColors';
38
43
  import NavigationTracker from './NavigationTracker';
@@ -51,6 +56,8 @@ const MainScreen = () => {
51
56
  selectedReduxAction,
52
57
  selectedCrash,
53
58
  settingsPage,
59
+ isFeedbackOpen,
60
+ setIsFeedbackOpen,
54
61
  activeTab,
55
62
  isReady,
56
63
  enabled,
@@ -93,6 +100,19 @@ const MainScreen = () => {
93
100
  }
94
101
  }, [settingsPage !== null]);
95
102
 
103
+ const feedbackAnim = useRef(new Animated.Value(0)).current;
104
+ useEffect(() => {
105
+ if (isFeedbackOpen) {
106
+ feedbackAnim.setValue(0);
107
+ Animated.spring(feedbackAnim, {
108
+ toValue: 1,
109
+ friction: 8,
110
+ tension: 65,
111
+ useNativeDriver: true,
112
+ }).start();
113
+ }
114
+ }, [isFeedbackOpen]);
115
+
96
116
  const tabAnim = useRef(new Animated.Value(1)).current;
97
117
  useEffect(() => {
98
118
  tabAnim.setValue(0);
@@ -113,8 +133,8 @@ const MainScreen = () => {
113
133
  visible={visible}
114
134
  animationType={modalAnimationType}
115
135
  transparent
116
- statusBarTranslucent={true}>
117
- {visible && (
136
+ statusBarTranslucent={true}
137
+ onRequestClose={closeModal}>
118
138
  <ErrorBoundary onClose={closeModal}>
119
139
  <View style={styles.modalBackdrop}>
120
140
  <Pressable
@@ -139,8 +159,8 @@ const MainScreen = () => {
139
159
  <InspectorHeader />
140
160
 
141
161
  <View style={{flex: 1}}>
142
- {/* ─── Horizontal Scrollable Tab Bar inside Content (Always visible) ─── */}
143
- {!isDetailActive && <TabBar />}
162
+ {/* ─── Horizontal Scrollable Tab Bar inside Content (Always visible unless in detail/settings/feedback) ─── */}
163
+ {!isDetailActive && settingsPage === null && !isFeedbackOpen && <TabBar />}
144
164
 
145
165
  {isReady ? (
146
166
  <View style={{flex: 1}}>
@@ -159,7 +179,7 @@ const MainScreen = () => {
159
179
  },
160
180
  ],
161
181
  },
162
- (isDetailActive || settingsPage !== null) && {
182
+ (isDetailActive || settingsPage !== null || isFeedbackOpen) && {
163
183
  pointerEvents: 'none',
164
184
  },
165
185
  ]}>
@@ -236,6 +256,39 @@ const MainScreen = () => {
236
256
  <SettingsPanel />
237
257
  </Animated.View>
238
258
  )}
259
+
260
+ {/* Support & Feedback Layer - Rendered inside in-app inspector covering full content card */}
261
+ {isFeedbackOpen && (
262
+ <Animated.View
263
+ style={[
264
+ StyleSheet.absoluteFill,
265
+ {
266
+ backgroundColor: AppColors.primaryLight,
267
+ opacity: feedbackAnim,
268
+ transform: [
269
+ {
270
+ translateY: feedbackAnim.interpolate({
271
+ inputRange: [0, 1],
272
+ outputRange: [24, 0],
273
+ }),
274
+ },
275
+ ],
276
+ },
277
+ ]}>
278
+ <FeedbackModal onClose={() => setIsFeedbackOpen(false)} />
279
+ </Animated.View>
280
+ )}
281
+
282
+ {/* Floating Support & Feedback Button (in place of scroll-to-top) */}
283
+ {!isDetailActive && settingsPage === null && !isFeedbackOpen && (
284
+ <TouchableOpacity
285
+ activeOpacity={0.8}
286
+ onPress={() => setIsFeedbackOpen(true)}
287
+ hitSlop={{top: 10, bottom: 10, left: 10, right: 10}}
288
+ style={styles.supportFab}>
289
+ <HeadphonesIcon color={AppColors.white} size={20} />
290
+ </TouchableOpacity>
291
+ )}
239
292
  </View>
240
293
 
241
294
  {/* Bottom floating toast notification */}
@@ -243,10 +296,12 @@ const MainScreen = () => {
243
296
 
244
297
  {/* NPM Version Update Toast with timeout progress bar */}
245
298
  <NpmUpdateToast />
299
+
300
+ {/* 5-Day Periodic Star & Support Prompt */}
301
+ <NpmStarPrompt />
246
302
  </View>
247
303
  </View>
248
304
  </ErrorBoundary>
249
- )}
250
305
  {hasNavigationContext && (
251
306
  <NavigationTracker onStateChange={setNavState} />
252
307
  )}