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.
- package/README.md +1 -0
- package/dist/commonjs/components/AnimatedEntrance.js +3 -3
- package/dist/commonjs/components/ConsoleLogCard.js +174 -100
- package/dist/commonjs/components/Inspector/AnalyticsTab.js +0 -22
- package/dist/commonjs/components/Inspector/ConsoleTab.js +25 -38
- package/dist/commonjs/components/Inspector/CrashTab.js +19 -28
- package/dist/commonjs/components/Inspector/DeviceInfoTab.js +198 -98
- package/dist/commonjs/components/Inspector/FeedbackModal.d.ts +7 -0
- package/dist/commonjs/components/Inspector/FeedbackModal.js +552 -0
- package/dist/commonjs/components/Inspector/InspectorHeader.js +58 -6
- package/dist/commonjs/components/Inspector/MainScreen.js +100 -58
- package/dist/commonjs/components/Inspector/NetworkTab.js +26 -371
- package/dist/commonjs/components/Inspector/NpmStarPrompt.d.ts +3 -0
- package/dist/commonjs/components/Inspector/NpmStarPrompt.js +494 -0
- package/dist/commonjs/components/Inspector/PerformanceTab.js +40 -7
- package/dist/commonjs/components/Inspector/ReduxTab.js +3 -23
- package/dist/commonjs/components/Inspector/SettingsPanel.js +1035 -173
- package/dist/commonjs/components/Inspector/StorageTab.js +23 -28
- package/dist/commonjs/components/Inspector/TabBar.js +50 -15
- package/dist/commonjs/components/JsonViewer.js +14 -2
- package/dist/commonjs/components/LogCard.js +428 -227
- package/dist/commonjs/components/NetworkIcons.d.ts +5 -0
- package/dist/commonjs/components/NetworkIcons.js +33 -2
- package/dist/commonjs/constants/version.d.ts +1 -1
- package/dist/commonjs/constants/version.js +1 -1
- package/dist/commonjs/customHooks/analyticsLogger.js +1 -1
- package/dist/commonjs/customHooks/consoleLogger.js +34 -2
- package/dist/commonjs/customHooks/crashHandler.js +1 -1
- package/dist/commonjs/customHooks/networkLogger.js +184 -26
- package/dist/commonjs/helpers/index.d.ts +1 -0
- package/dist/commonjs/helpers/index.js +1 -0
- package/dist/commonjs/helpers/remoteConfig.d.ts +4 -0
- package/dist/commonjs/helpers/remoteConfig.js +165 -0
- package/dist/commonjs/helpers/searchQueryParser.d.ts +1 -1
- package/dist/commonjs/helpers/searchQueryParser.js +39 -291
- package/dist/commonjs/helpers/telemetry.d.ts +5 -0
- package/dist/commonjs/helpers/telemetry.js +339 -8
- package/dist/commonjs/index.d.ts +1 -0
- package/dist/commonjs/index.js +173 -29
- package/dist/commonjs/styles/AppFonts.d.ts +2 -0
- package/dist/commonjs/styles/AppFonts.js +1 -0
- package/dist/commonjs/styles/index.d.ts +22 -0
- package/dist/commonjs/styles/index.js +19 -0
- package/dist/commonjs/types/enums.d.ts +1 -0
- package/dist/commonjs/types/enums.js +1 -0
- package/dist/commonjs/types/interfaces.d.ts +12 -0
- package/dist/esm/components/AnimatedEntrance.js +3 -3
- package/dist/esm/components/ConsoleLogCard.js +141 -100
- package/dist/esm/components/Inspector/AnalyticsTab.js +1 -23
- package/dist/esm/components/Inspector/ConsoleTab.js +26 -39
- package/dist/esm/components/Inspector/CrashTab.js +20 -29
- package/dist/esm/components/Inspector/DeviceInfoTab.js +198 -98
- package/dist/esm/components/Inspector/FeedbackModal.d.ts +7 -0
- package/dist/esm/components/Inspector/FeedbackModal.js +515 -0
- package/dist/esm/components/Inspector/InspectorHeader.js +60 -8
- package/dist/esm/components/Inspector/MainScreen.js +101 -59
- package/dist/esm/components/Inspector/NetworkTab.js +27 -372
- package/dist/esm/components/Inspector/NpmStarPrompt.d.ts +3 -0
- package/dist/esm/components/Inspector/NpmStarPrompt.js +454 -0
- package/dist/esm/components/Inspector/PerformanceTab.js +40 -7
- package/dist/esm/components/Inspector/ReduxTab.js +4 -24
- package/dist/esm/components/Inspector/SettingsPanel.js +1038 -176
- package/dist/esm/components/Inspector/StorageTab.js +23 -28
- package/dist/esm/components/Inspector/TabBar.js +50 -15
- package/dist/esm/components/JsonViewer.js +14 -2
- package/dist/esm/components/LogCard.js +422 -221
- package/dist/esm/components/NetworkIcons.d.ts +5 -0
- package/dist/esm/components/NetworkIcons.js +26 -0
- package/dist/esm/constants/version.d.ts +1 -1
- package/dist/esm/constants/version.js +1 -1
- package/dist/esm/customHooks/analyticsLogger.js +1 -1
- package/dist/esm/customHooks/consoleLogger.js +34 -2
- package/dist/esm/customHooks/crashHandler.js +1 -1
- package/dist/esm/customHooks/networkLogger.js +184 -26
- package/dist/esm/helpers/index.d.ts +1 -0
- package/dist/esm/helpers/index.js +1 -0
- package/dist/esm/helpers/remoteConfig.d.ts +4 -0
- package/dist/esm/helpers/remoteConfig.js +160 -0
- package/dist/esm/helpers/searchQueryParser.d.ts +1 -1
- package/dist/esm/helpers/searchQueryParser.js +39 -291
- package/dist/esm/helpers/telemetry.d.ts +5 -0
- package/dist/esm/helpers/telemetry.js +332 -9
- package/dist/esm/index.d.ts +1 -0
- package/dist/esm/index.js +171 -29
- package/dist/esm/styles/AppFonts.d.ts +2 -0
- package/dist/esm/styles/AppFonts.js +1 -0
- package/dist/esm/styles/index.d.ts +22 -0
- package/dist/esm/styles/index.js +19 -0
- package/dist/esm/types/enums.d.ts +1 -0
- package/dist/esm/types/enums.js +1 -0
- package/dist/esm/types/interfaces.d.ts +12 -0
- package/package.json +1 -1
- package/src/components/AnimatedEntrance.tsx +3 -3
- package/src/components/ConsoleLogCard.tsx +154 -103
- package/src/components/Inspector/AnalyticsTab.tsx +0 -23
- package/src/components/Inspector/ConsoleTab.tsx +27 -41
- package/src/components/Inspector/CrashTab.tsx +19 -28
- package/src/components/Inspector/DeviceInfoTab.tsx +224 -102
- package/src/components/Inspector/FeedbackModal.tsx +626 -0
- package/src/components/Inspector/InspectorHeader.tsx +83 -5
- package/src/components/Inspector/MainScreen.tsx +61 -6
- package/src/components/Inspector/NetworkTab.tsx +70 -480
- package/src/components/Inspector/NpmStarPrompt.tsx +532 -0
- package/src/components/Inspector/PerformanceTab.tsx +44 -8
- package/src/components/Inspector/ReduxTab.tsx +9 -24
- package/src/components/Inspector/SettingsPanel.tsx +1162 -197
- package/src/components/Inspector/StorageTab.tsx +27 -30
- package/src/components/Inspector/TabBar.tsx +57 -20
- package/src/components/JsonViewer.tsx +15 -2
- package/src/components/LogCard.tsx +528 -339
- package/src/components/NetworkIcons.tsx +92 -0
- package/src/constants/version.ts +1 -1
- package/src/customHooks/analyticsLogger.ts +1 -1
- package/src/customHooks/consoleLogger.ts +36 -3
- package/src/customHooks/crashHandler.ts +1 -1
- package/src/customHooks/networkLogger.ts +214 -26
- package/src/helpers/index.ts +1 -0
- package/src/helpers/remoteConfig.ts +212 -0
- package/src/helpers/searchQueryParser.ts +42 -284
- package/src/helpers/telemetry.ts +381 -10
- package/src/index.tsx +374 -211
- package/src/styles/AppFonts.ts +2 -0
- package/src/styles/index.ts +20 -1
- package/src/types/enums.ts +1 -0
- 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
|
-
{
|
|
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
|
-
|
|
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={
|
|
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
|
-
</
|
|
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
|
-
|
|
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
|
)}
|