react-native-inapp-inspector 1.1.27 → 1.1.29
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/android/src/main/java/com/inappinspector/NetworkInspectorModule.java +29 -46
- package/dist/commonjs/components/AppHeaderLogo.js +12 -15
- package/dist/commonjs/components/ConsoleLogCard.js +31 -7
- package/dist/commonjs/components/CopyButton.js +15 -1
- package/dist/commonjs/components/DomainHeader.js +56 -28
- package/dist/commonjs/components/ErrorBoundary.d.ts +1 -1
- package/dist/commonjs/components/ErrorBoundary.js +530 -100
- package/dist/commonjs/components/HighlightText.js +7 -1
- package/dist/commonjs/components/Inspector/AnalyticsTab.js +190 -126
- package/dist/commonjs/components/Inspector/BundleTab.d.ts +1 -0
- package/dist/commonjs/components/Inspector/BundleTab.js +145 -21
- package/dist/commonjs/components/Inspector/CrashTab.js +0 -8
- package/dist/commonjs/components/Inspector/InspectorHeader.js +17 -3
- package/dist/commonjs/components/Inspector/LogDetail.js +8 -5
- package/dist/commonjs/components/Inspector/MainScreen.js +4 -0
- package/dist/commonjs/components/Inspector/NetworkDetail.js +65 -24
- package/dist/commonjs/components/Inspector/PerformanceTab.d.ts +5 -0
- package/dist/commonjs/components/Inspector/PerformanceTab.js +588 -155
- package/dist/commonjs/components/Inspector/SettingsPanel.js +57 -22
- package/dist/commonjs/components/Inspector/TabBar.js +13 -1
- package/dist/commonjs/components/JsonViewer.js +25 -3
- package/dist/commonjs/components/LogCard.js +173 -40
- package/dist/commonjs/components/NetworkIcons.d.ts +112 -102
- package/dist/commonjs/components/Toast.d.ts +3 -0
- package/dist/commonjs/components/Toast.js +152 -0
- package/dist/commonjs/components/TouchableScale.d.ts +1 -0
- package/dist/commonjs/components/TouchableScale.js +3 -3
- package/dist/commonjs/components/TreeNode.js +1 -1
- package/dist/commonjs/constants/index.js +6 -6
- package/dist/commonjs/constants/version.d.ts +1 -1
- package/dist/commonjs/constants/version.js +1 -1
- package/dist/commonjs/customHooks/analyticsLogger.d.ts +1 -11
- package/dist/commonjs/customHooks/analyticsLogger.js +8 -1
- package/dist/commonjs/customHooks/bundleAnalyzer.js +121 -124
- package/dist/commonjs/customHooks/networkLogger.d.ts +1 -0
- package/dist/commonjs/customHooks/networkLogger.js +16 -0
- package/dist/commonjs/customHooks/performanceTracker.d.ts +74 -0
- package/dist/commonjs/customHooks/performanceTracker.js +546 -392
- package/dist/commonjs/customHooks/reduxLogger.d.ts +1 -0
- package/dist/commonjs/customHooks/reduxLogger.js +3 -1
- package/dist/commonjs/helpers/index.d.ts +4 -0
- package/dist/commonjs/helpers/index.js +92 -69
- package/dist/commonjs/helpers/toast.d.ts +4 -0
- package/dist/commonjs/helpers/toast.js +20 -0
- package/dist/commonjs/i18n/locales/en.json +229 -5
- package/dist/commonjs/index.d.ts +1 -1
- package/dist/commonjs/index.js +36 -2
- package/dist/commonjs/styles/index.d.ts +63 -15
- package/dist/commonjs/styles/index.js +79 -32
- package/dist/commonjs/types/interfaces.d.ts +3 -0
- package/dist/esm/components/AppHeaderLogo.js +12 -15
- package/dist/esm/components/ConsoleLogCard.js +33 -9
- package/dist/esm/components/CopyButton.js +15 -1
- package/dist/esm/components/DomainHeader.js +56 -28
- package/dist/esm/components/ErrorBoundary.d.ts +1 -1
- package/dist/esm/components/ErrorBoundary.js +498 -101
- package/dist/esm/components/HighlightText.js +7 -1
- package/dist/esm/components/Inspector/AnalyticsTab.js +191 -127
- package/dist/esm/components/Inspector/BundleTab.d.ts +1 -0
- package/dist/esm/components/Inspector/BundleTab.js +145 -23
- package/dist/esm/components/Inspector/CrashTab.js +0 -8
- package/dist/esm/components/Inspector/InspectorHeader.js +18 -4
- package/dist/esm/components/Inspector/LogDetail.js +10 -7
- package/dist/esm/components/Inspector/MainScreen.js +4 -0
- package/dist/esm/components/Inspector/NetworkDetail.js +66 -25
- package/dist/esm/components/Inspector/PerformanceTab.d.ts +5 -0
- package/dist/esm/components/Inspector/PerformanceTab.js +591 -158
- package/dist/esm/components/Inspector/SettingsPanel.js +57 -22
- package/dist/esm/components/Inspector/TabBar.js +13 -1
- package/dist/esm/components/JsonViewer.js +25 -3
- package/dist/esm/components/LogCard.js +175 -42
- package/dist/esm/components/NetworkIcons.d.ts +112 -102
- package/dist/esm/components/Toast.d.ts +3 -0
- package/dist/esm/components/Toast.js +117 -0
- package/dist/esm/components/TouchableScale.d.ts +1 -0
- package/dist/esm/components/TouchableScale.js +3 -3
- package/dist/esm/components/TreeNode.js +1 -1
- package/dist/esm/constants/index.js +6 -6
- package/dist/esm/constants/version.d.ts +1 -1
- package/dist/esm/constants/version.js +1 -1
- package/dist/esm/customHooks/analyticsLogger.d.ts +1 -11
- package/dist/esm/customHooks/analyticsLogger.js +6 -0
- package/dist/esm/customHooks/bundleAnalyzer.js +121 -124
- package/dist/esm/customHooks/networkLogger.d.ts +1 -0
- package/dist/esm/customHooks/networkLogger.js +16 -0
- package/dist/esm/customHooks/performanceTracker.d.ts +74 -0
- package/dist/esm/customHooks/performanceTracker.js +531 -391
- package/dist/esm/customHooks/reduxLogger.d.ts +1 -0
- package/dist/esm/customHooks/reduxLogger.js +1 -0
- package/dist/esm/helpers/index.d.ts +4 -0
- package/dist/esm/helpers/index.js +87 -69
- package/dist/esm/helpers/toast.d.ts +4 -0
- package/dist/esm/helpers/toast.js +15 -0
- package/dist/esm/i18n/locales/en.json +229 -5
- package/dist/esm/index.d.ts +1 -1
- package/dist/esm/index.js +24 -3
- package/dist/esm/styles/index.d.ts +63 -15
- package/dist/esm/styles/index.js +79 -32
- package/dist/esm/types/interfaces.d.ts +3 -0
- package/package.json +4 -1
package/dist/commonjs/index.js
CHANGED
|
@@ -36,8 +36,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
36
36
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
37
37
|
};
|
|
38
38
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39
|
-
exports.
|
|
40
|
-
exports.BreadcrumbType = exports.CrashFilterType = exports.CrashDetailSubTab = exports.CrashExportFormat = exports.CrashType = exports.PerformanceSubTab = exports.BundleSubTab = exports.DiffResultType = exports.StackFrameType = exports.GAEventCategory = exports.AnalyticsEventSource = exports.ConsoleLogType = exports.LogFilter = exports.SettingsSubTab = exports.SettingsPage = exports.ModalAnimationType = exports.LocalFilter = exports.SortOrder = exports.StatusFilter = exports.Method = void 0;
|
|
39
|
+
exports.registerComponentProfile = exports.getHermesMemoryStats = exports.measureAsync = exports.trackHeavyTask = exports.trackNavigationTransition = exports.trackComponentRender = exports.useNavigationProfiler = exports.useComponentProfiler = exports.usePerformanceTracker = exports.registerGAPlugin = exports.getEventCategory = exports.getLastActionForReducer = exports.clearActionHistory = exports.getActionHistory = exports.subscribeReduxState = exports.getReduxState = exports.inspectorReduxMiddleware = exports.connectReduxStore = exports.ErrorBoundary = exports.CrashTab = exports.computeCrashFingerprint = exports.recordUserActionBreadcrumb = exports.recordReduxBreadcrumb = exports.recordNetworkBreadcrumb = exports.recordNavigationBreadcrumb = exports.addCrashBreadcrumb = exports.recordCustomCrash = exports.parseCrashStackTrace = exports.exportCrashReport = exports.simulateTestCrash = exports.clearCrashRecords = exports.getCrashRecords = exports.emitCrashEvent = exports.subscribeCrashEvents = exports.setupGlobalCrashHandler = exports.getCollectionEnabled = exports.getDefaultEventParameters = exports.getCurrentUserId = exports.getCurrentUserProperties = exports.clearAnalyticsEvents = exports.subscribeAnalyticsEvents = exports.logAnalyticsEvent = exports.setupAnalyticsLogger = exports.subscribeConsoleLogs = exports.clearConsoleLogs = exports.setupConsoleLogger = exports.addAxiosInterceptors = exports.subscribeNetworkLogs = exports.clearNetworkLogs = exports.setupNetworkLogger = void 0;
|
|
40
|
+
exports.BreadcrumbType = exports.CrashFilterType = exports.CrashDetailSubTab = exports.CrashExportFormat = exports.CrashType = exports.PerformanceSubTab = exports.BundleSubTab = exports.DiffResultType = exports.StackFrameType = exports.GAEventCategory = exports.AnalyticsEventSource = exports.ConsoleLogType = exports.LogFilter = exports.SettingsSubTab = exports.SettingsPage = exports.ModalAnimationType = exports.LocalFilter = exports.SortOrder = exports.StatusFilter = exports.Method = exports.ActiveTab = exports.InspectCatch = exports.InspectTrackTime = exports.InspectLog = exports.generateFixSnippet = exports.getInitialPerformanceEvents = exports.getInitialRenderProfiles = exports.getPerformanceEvents = exports.subscribePerformanceEvents = exports.clearPerformanceEvents = exports.logPerformanceEvent = exports.getRenderProfiles = exports.subscribeRenderProfiles = void 0;
|
|
41
41
|
const react_1 = __importStar(require("react"));
|
|
42
42
|
const react_native_1 = require("react-native");
|
|
43
43
|
const native_1 = require("@react-navigation/native");
|
|
@@ -375,9 +375,22 @@ const NetworkInspector = ({ enabled = true, isEnabled = true, storage, navigatio
|
|
|
375
375
|
(0, react_1.useEffect)(() => {
|
|
376
376
|
(0, reduxLogger_1.setReduxAutoRefresh)(reduxAutoRefresh);
|
|
377
377
|
}, [reduxAutoRefresh]);
|
|
378
|
+
// Auto-unselect Redux or Analytics tab if module is not connected / available
|
|
379
|
+
(0, react_1.useEffect)(() => {
|
|
380
|
+
if (activeTab === 'redux' && !(0, reduxLogger_1.isReduxConnected)()) {
|
|
381
|
+
setActiveTab('apis');
|
|
382
|
+
}
|
|
383
|
+
if (activeTab === 'analytics' && !(0, analyticsLogger_1.isAnalyticsConnected)()) {
|
|
384
|
+
setActiveTab('apis');
|
|
385
|
+
}
|
|
386
|
+
}, [activeTab]);
|
|
378
387
|
const toggleTabVisibility = (key) => {
|
|
379
388
|
if (key === 'apis')
|
|
380
389
|
return;
|
|
390
|
+
if (key === 'redux' && !(0, reduxLogger_1.isReduxConnected)())
|
|
391
|
+
return;
|
|
392
|
+
if (key === 'analytics' && !(0, analyticsLogger_1.isAnalyticsConnected)())
|
|
393
|
+
return;
|
|
381
394
|
setTabVisibility(prev => {
|
|
382
395
|
const nextVal = !prev[key];
|
|
383
396
|
const newVisibility = { ...prev, [key]: nextVal };
|
|
@@ -393,6 +406,10 @@ const NetworkInspector = ({ enabled = true, isEnabled = true, storage, navigatio
|
|
|
393
406
|
});
|
|
394
407
|
};
|
|
395
408
|
const switchActiveTab = (0, react_1.useCallback)((key) => {
|
|
409
|
+
if (key === 'redux' && !(0, reduxLogger_1.isReduxConnected)())
|
|
410
|
+
return;
|
|
411
|
+
if (key === 'analytics' && !(0, analyticsLogger_1.isAnalyticsConnected)())
|
|
412
|
+
return;
|
|
396
413
|
setActiveTab(key);
|
|
397
414
|
}, []);
|
|
398
415
|
const [selectedEvent, setSelectedEvent] = (0, react_1.useState)(null);
|
|
@@ -1228,6 +1245,10 @@ const NetworkInspector = ({ enabled = true, isEnabled = true, storage, navigatio
|
|
|
1228
1245
|
setVisible(false);
|
|
1229
1246
|
setSelected(null);
|
|
1230
1247
|
setSelectedEvent(null);
|
|
1248
|
+
setSelectedLog(null);
|
|
1249
|
+
setSelectedReduxSlice(null);
|
|
1250
|
+
setSelectedReduxAction(null);
|
|
1251
|
+
setSelectedCrash(null);
|
|
1231
1252
|
}
|
|
1232
1253
|
function handleClearAll() {
|
|
1233
1254
|
(0, networkLogger_1.clearNetworkLogs)();
|
|
@@ -1592,10 +1613,23 @@ Object.defineProperty(exports, "getEventCategory", { enumerable: true, get: func
|
|
|
1592
1613
|
Object.defineProperty(exports, "registerGAPlugin", { enumerable: true, get: function () { return gaAnalyticsRegistry_1.registerGAPlugin; } });
|
|
1593
1614
|
var performanceTracker_1 = require("./customHooks/performanceTracker");
|
|
1594
1615
|
Object.defineProperty(exports, "usePerformanceTracker", { enumerable: true, get: function () { return performanceTracker_1.usePerformanceTracker; } });
|
|
1616
|
+
Object.defineProperty(exports, "useComponentProfiler", { enumerable: true, get: function () { return performanceTracker_1.useComponentProfiler; } });
|
|
1617
|
+
Object.defineProperty(exports, "useNavigationProfiler", { enumerable: true, get: function () { return performanceTracker_1.useNavigationProfiler; } });
|
|
1618
|
+
Object.defineProperty(exports, "trackComponentRender", { enumerable: true, get: function () { return performanceTracker_1.trackComponentRender; } });
|
|
1619
|
+
Object.defineProperty(exports, "trackNavigationTransition", { enumerable: true, get: function () { return performanceTracker_1.trackNavigationTransition; } });
|
|
1620
|
+
Object.defineProperty(exports, "trackHeavyTask", { enumerable: true, get: function () { return performanceTracker_1.trackHeavyTask; } });
|
|
1621
|
+
Object.defineProperty(exports, "measureAsync", { enumerable: true, get: function () { return performanceTracker_1.measureAsync; } });
|
|
1622
|
+
Object.defineProperty(exports, "getHermesMemoryStats", { enumerable: true, get: function () { return performanceTracker_1.getHermesMemoryStats; } });
|
|
1623
|
+
Object.defineProperty(exports, "registerComponentProfile", { enumerable: true, get: function () { return performanceTracker_1.registerComponentProfile; } });
|
|
1624
|
+
Object.defineProperty(exports, "subscribeRenderProfiles", { enumerable: true, get: function () { return performanceTracker_1.subscribeRenderProfiles; } });
|
|
1625
|
+
Object.defineProperty(exports, "getRenderProfiles", { enumerable: true, get: function () { return performanceTracker_1.getRenderProfiles; } });
|
|
1595
1626
|
Object.defineProperty(exports, "logPerformanceEvent", { enumerable: true, get: function () { return performanceTracker_1.logPerformanceEvent; } });
|
|
1596
1627
|
Object.defineProperty(exports, "clearPerformanceEvents", { enumerable: true, get: function () { return performanceTracker_1.clearPerformanceEvents; } });
|
|
1597
1628
|
Object.defineProperty(exports, "subscribePerformanceEvents", { enumerable: true, get: function () { return performanceTracker_1.subscribePerformanceEvents; } });
|
|
1598
1629
|
Object.defineProperty(exports, "getPerformanceEvents", { enumerable: true, get: function () { return performanceTracker_1.getPerformanceEvents; } });
|
|
1630
|
+
Object.defineProperty(exports, "getInitialRenderProfiles", { enumerable: true, get: function () { return performanceTracker_1.getInitialRenderProfiles; } });
|
|
1631
|
+
Object.defineProperty(exports, "getInitialPerformanceEvents", { enumerable: true, get: function () { return performanceTracker_1.getInitialPerformanceEvents; } });
|
|
1632
|
+
Object.defineProperty(exports, "generateFixSnippet", { enumerable: true, get: function () { return performanceTracker_1.generateFixSnippet; } });
|
|
1599
1633
|
var decorators_1 = require("./decorators");
|
|
1600
1634
|
Object.defineProperty(exports, "InspectLog", { enumerable: true, get: function () { return decorators_1.InspectLog; } });
|
|
1601
1635
|
Object.defineProperty(exports, "InspectTrackTime", { enumerable: true, get: function () { return decorators_1.InspectTrackTime; } });
|
|
@@ -20,17 +20,22 @@ export declare const getRawStyles: (colors: typeof AppColors) => {
|
|
|
20
20
|
};
|
|
21
21
|
headerLeft: {
|
|
22
22
|
flex: number;
|
|
23
|
+
minWidth: number;
|
|
23
24
|
alignItems: string;
|
|
24
25
|
};
|
|
25
26
|
headerCenter: {
|
|
26
27
|
flex: number;
|
|
28
|
+
minWidth: number;
|
|
27
29
|
alignItems: string;
|
|
30
|
+
justifyContent: string;
|
|
31
|
+
paddingHorizontal: number;
|
|
28
32
|
};
|
|
29
33
|
headerRight: {
|
|
30
|
-
|
|
34
|
+
flexShrink: number;
|
|
31
35
|
flexDirection: string;
|
|
32
36
|
alignItems: string;
|
|
33
37
|
justifyContent: string;
|
|
38
|
+
gap: number;
|
|
34
39
|
};
|
|
35
40
|
headerTitle: {
|
|
36
41
|
fontFamily: string;
|
|
@@ -176,6 +181,7 @@ export declare const getRawStyles: (colors: typeof AppColors) => {
|
|
|
176
181
|
justifyContent: string;
|
|
177
182
|
borderWidth: number;
|
|
178
183
|
borderColor: string;
|
|
184
|
+
overflow: string;
|
|
179
185
|
};
|
|
180
186
|
fabWrapper: {
|
|
181
187
|
position: string;
|
|
@@ -250,6 +256,13 @@ export declare const getRawStyles: (colors: typeof AppColors) => {
|
|
|
250
256
|
gap: number;
|
|
251
257
|
};
|
|
252
258
|
toolbarBtn: {
|
|
259
|
+
shadowColor: string;
|
|
260
|
+
shadowOffset: {
|
|
261
|
+
width: number;
|
|
262
|
+
height: number;
|
|
263
|
+
};
|
|
264
|
+
shadowOpacity: number;
|
|
265
|
+
shadowRadius: number;
|
|
253
266
|
width: number;
|
|
254
267
|
height: number;
|
|
255
268
|
borderRadius: number;
|
|
@@ -258,14 +271,16 @@ export declare const getRawStyles: (colors: typeof AppColors) => {
|
|
|
258
271
|
backgroundColor: string;
|
|
259
272
|
borderWidth: number;
|
|
260
273
|
borderColor: string;
|
|
261
|
-
|
|
262
|
-
shadowOffset: {
|
|
263
|
-
width: number;
|
|
264
|
-
height: number;
|
|
265
|
-
};
|
|
266
|
-
shadowOpacity: number;
|
|
267
|
-
shadowRadius: number;
|
|
274
|
+
} | {
|
|
268
275
|
elevation: number;
|
|
276
|
+
width: number;
|
|
277
|
+
height: number;
|
|
278
|
+
borderRadius: number;
|
|
279
|
+
alignItems: string;
|
|
280
|
+
justifyContent: string;
|
|
281
|
+
backgroundColor: string;
|
|
282
|
+
borderWidth: number;
|
|
283
|
+
borderColor: string;
|
|
269
284
|
};
|
|
270
285
|
toolbarBtnActive: {
|
|
271
286
|
borderColor: string;
|
|
@@ -452,18 +467,38 @@ export declare const getRawStyles: (colors: typeof AppColors) => {
|
|
|
452
467
|
fontFamily: string;
|
|
453
468
|
fontSize: number;
|
|
454
469
|
};
|
|
470
|
+
domainProgressSection: {
|
|
471
|
+
marginTop: number;
|
|
472
|
+
gap: number;
|
|
473
|
+
width: string;
|
|
474
|
+
};
|
|
455
475
|
domainProgressTrack: {
|
|
456
476
|
flexDirection: string;
|
|
457
477
|
height: number;
|
|
458
478
|
borderRadius: number;
|
|
459
479
|
overflow: string;
|
|
460
480
|
backgroundColor: string;
|
|
461
|
-
marginTop: number;
|
|
462
481
|
width: string;
|
|
463
482
|
};
|
|
464
483
|
domainProgressSegment: {
|
|
465
484
|
height: string;
|
|
466
485
|
};
|
|
486
|
+
domainProgressLabelsRow: {
|
|
487
|
+
flexDirection: string;
|
|
488
|
+
alignItems: string;
|
|
489
|
+
justifyContent: string;
|
|
490
|
+
paddingHorizontal: number;
|
|
491
|
+
};
|
|
492
|
+
domainProgressRateText: {
|
|
493
|
+
fontFamily: string;
|
|
494
|
+
fontSize: number;
|
|
495
|
+
color: string;
|
|
496
|
+
};
|
|
497
|
+
domainProgressSummaryText: {
|
|
498
|
+
fontFamily: string;
|
|
499
|
+
fontSize: number;
|
|
500
|
+
color: string;
|
|
501
|
+
};
|
|
467
502
|
domainStatsGroup: {
|
|
468
503
|
flexDirection: string;
|
|
469
504
|
alignItems: string;
|
|
@@ -580,11 +615,6 @@ export declare const getRawStyles: (colors: typeof AppColors) => {
|
|
|
580
615
|
fontSize: number;
|
|
581
616
|
};
|
|
582
617
|
methodBadge: {
|
|
583
|
-
paddingHorizontal: number;
|
|
584
|
-
paddingVertical: number;
|
|
585
|
-
borderRadius: number;
|
|
586
|
-
alignItems: string;
|
|
587
|
-
justifyContent: string;
|
|
588
618
|
shadowColor: string;
|
|
589
619
|
shadowOffset: {
|
|
590
620
|
width: number;
|
|
@@ -592,12 +622,28 @@ export declare const getRawStyles: (colors: typeof AppColors) => {
|
|
|
592
622
|
};
|
|
593
623
|
shadowOpacity: number;
|
|
594
624
|
shadowRadius: number;
|
|
625
|
+
paddingHorizontal: number;
|
|
626
|
+
paddingVertical: number;
|
|
627
|
+
borderRadius: number;
|
|
628
|
+
alignItems: string;
|
|
629
|
+
justifyContent: string;
|
|
630
|
+
borderWidth: number;
|
|
631
|
+
borderColor: string;
|
|
632
|
+
} | {
|
|
595
633
|
elevation: number;
|
|
634
|
+
paddingHorizontal: number;
|
|
635
|
+
paddingVertical: number;
|
|
636
|
+
borderRadius: number;
|
|
637
|
+
alignItems: string;
|
|
638
|
+
justifyContent: string;
|
|
639
|
+
borderWidth: number;
|
|
640
|
+
borderColor: string;
|
|
596
641
|
};
|
|
597
642
|
methodBadgeText: {
|
|
598
643
|
fontFamily: string;
|
|
599
644
|
fontSize: number;
|
|
600
645
|
letterSpacing: number;
|
|
646
|
+
color: string;
|
|
601
647
|
};
|
|
602
648
|
cardHostText: {
|
|
603
649
|
fontFamily: string;
|
|
@@ -645,12 +691,14 @@ export declare const getRawStyles: (colors: typeof AppColors) => {
|
|
|
645
691
|
paddingHorizontal: number;
|
|
646
692
|
paddingVertical: number;
|
|
647
693
|
borderRadius: number;
|
|
694
|
+
marginTop: number;
|
|
648
695
|
};
|
|
649
696
|
slugText: {
|
|
650
697
|
fontFamily: string;
|
|
651
698
|
fontSize: number;
|
|
699
|
+
lineHeight: number;
|
|
652
700
|
color: string;
|
|
653
|
-
|
|
701
|
+
flex: number;
|
|
654
702
|
};
|
|
655
703
|
slugRight: {
|
|
656
704
|
flexDirection: string;
|
|
@@ -43,23 +43,34 @@ const getRawStyles = (colors) => ({
|
|
|
43
43
|
header: {
|
|
44
44
|
flexDirection: 'row',
|
|
45
45
|
alignItems: 'center',
|
|
46
|
-
paddingHorizontal:
|
|
47
|
-
paddingVertical:
|
|
46
|
+
paddingHorizontal: 10,
|
|
47
|
+
paddingVertical: 8,
|
|
48
48
|
zIndex: 10,
|
|
49
|
-
minHeight:
|
|
49
|
+
minHeight: 56,
|
|
50
50
|
shadowColor: colors.black,
|
|
51
51
|
shadowOffset: { width: 0, height: 2 },
|
|
52
52
|
shadowOpacity: 0.08,
|
|
53
53
|
shadowRadius: 4,
|
|
54
|
-
elevation:
|
|
54
|
+
elevation: 3,
|
|
55
55
|
},
|
|
56
|
-
headerLeft: {
|
|
57
|
-
|
|
58
|
-
|
|
56
|
+
headerLeft: {
|
|
57
|
+
flex: 1,
|
|
58
|
+
minWidth: 0,
|
|
59
|
+
alignItems: 'flex-start',
|
|
60
|
+
},
|
|
61
|
+
headerCenter: {
|
|
59
62
|
flex: 1,
|
|
63
|
+
minWidth: 0,
|
|
64
|
+
alignItems: 'center',
|
|
65
|
+
justifyContent: 'center',
|
|
66
|
+
paddingHorizontal: 4,
|
|
67
|
+
},
|
|
68
|
+
headerRight: {
|
|
69
|
+
flexShrink: 0,
|
|
60
70
|
flexDirection: 'row',
|
|
61
71
|
alignItems: 'center',
|
|
62
72
|
justifyContent: 'flex-end',
|
|
73
|
+
gap: 6,
|
|
63
74
|
},
|
|
64
75
|
headerTitle: {
|
|
65
76
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
@@ -185,11 +196,12 @@ const getRawStyles = (colors) => ({
|
|
|
185
196
|
width: 32,
|
|
186
197
|
height: 32,
|
|
187
198
|
borderRadius: 8,
|
|
188
|
-
backgroundColor: `${colors.white}
|
|
199
|
+
backgroundColor: `${colors.white}2B`,
|
|
189
200
|
alignItems: 'center',
|
|
190
201
|
justifyContent: 'center',
|
|
191
202
|
borderWidth: 1,
|
|
192
|
-
borderColor: `${colors.white}
|
|
203
|
+
borderColor: `${colors.white}33`,
|
|
204
|
+
overflow: 'hidden',
|
|
193
205
|
},
|
|
194
206
|
fabWrapper: {
|
|
195
207
|
position: 'absolute',
|
|
@@ -266,11 +278,16 @@ const getRawStyles = (colors) => ({
|
|
|
266
278
|
backgroundColor: colors.primaryLight,
|
|
267
279
|
borderWidth: 1.5,
|
|
268
280
|
borderColor: colors.grayBorderSecondary,
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
281
|
+
...(react_native_1.Platform.OS === 'ios'
|
|
282
|
+
? {
|
|
283
|
+
shadowColor: colors.black,
|
|
284
|
+
shadowOffset: { width: 0, height: 1 },
|
|
285
|
+
shadowOpacity: 0.04,
|
|
286
|
+
shadowRadius: 2,
|
|
287
|
+
}
|
|
288
|
+
: {
|
|
289
|
+
elevation: 0,
|
|
290
|
+
}),
|
|
274
291
|
},
|
|
275
292
|
toolbarBtnActive: {
|
|
276
293
|
borderColor: colors.purple,
|
|
@@ -447,18 +464,38 @@ const getRawStyles = (colors) => ({
|
|
|
447
464
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
448
465
|
fontSize: 9.5,
|
|
449
466
|
},
|
|
467
|
+
domainProgressSection: {
|
|
468
|
+
marginTop: 8,
|
|
469
|
+
gap: 4,
|
|
470
|
+
width: '100%',
|
|
471
|
+
},
|
|
450
472
|
domainProgressTrack: {
|
|
451
473
|
flexDirection: 'row',
|
|
452
|
-
height:
|
|
453
|
-
borderRadius:
|
|
474
|
+
height: 4,
|
|
475
|
+
borderRadius: 2,
|
|
454
476
|
overflow: 'hidden',
|
|
455
|
-
backgroundColor: '
|
|
456
|
-
marginTop: 6,
|
|
477
|
+
backgroundColor: '#E2E8F0',
|
|
457
478
|
width: '100%',
|
|
458
479
|
},
|
|
459
480
|
domainProgressSegment: {
|
|
460
481
|
height: '100%',
|
|
461
482
|
},
|
|
483
|
+
domainProgressLabelsRow: {
|
|
484
|
+
flexDirection: 'row',
|
|
485
|
+
alignItems: 'center',
|
|
486
|
+
justifyContent: 'space-between',
|
|
487
|
+
paddingHorizontal: 2,
|
|
488
|
+
},
|
|
489
|
+
domainProgressRateText: {
|
|
490
|
+
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
491
|
+
fontSize: 9.5,
|
|
492
|
+
color: colors.grayTextStrong,
|
|
493
|
+
},
|
|
494
|
+
domainProgressSummaryText: {
|
|
495
|
+
fontFamily: AppFonts_1.AppFonts.interMedium,
|
|
496
|
+
fontSize: 9,
|
|
497
|
+
color: colors.grayTextWeak,
|
|
498
|
+
},
|
|
462
499
|
domainStatsGroup: {
|
|
463
500
|
flexDirection: 'row',
|
|
464
501
|
alignItems: 'center',
|
|
@@ -572,21 +609,29 @@ const getRawStyles = (colors) => ({
|
|
|
572
609
|
fontSize: 10,
|
|
573
610
|
},
|
|
574
611
|
methodBadge: {
|
|
575
|
-
paddingHorizontal: 6,
|
|
612
|
+
paddingHorizontal: 6.5,
|
|
576
613
|
paddingVertical: 2.5,
|
|
577
|
-
borderRadius:
|
|
614
|
+
borderRadius: 5,
|
|
578
615
|
alignItems: 'center',
|
|
579
616
|
justifyContent: 'center',
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
617
|
+
borderWidth: 1,
|
|
618
|
+
borderColor: 'rgba(255, 255, 255, 0.3)',
|
|
619
|
+
...(react_native_1.Platform.OS === 'ios'
|
|
620
|
+
? {
|
|
621
|
+
shadowColor: colors.black,
|
|
622
|
+
shadowOffset: { width: 0, height: 1 },
|
|
623
|
+
shadowOpacity: 0.12,
|
|
624
|
+
shadowRadius: 2,
|
|
625
|
+
}
|
|
626
|
+
: {
|
|
627
|
+
elevation: 1,
|
|
628
|
+
}),
|
|
585
629
|
},
|
|
586
630
|
methodBadgeText: {
|
|
587
631
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
588
632
|
fontSize: 9.5,
|
|
589
|
-
letterSpacing: 0.
|
|
633
|
+
letterSpacing: 0.6,
|
|
634
|
+
color: colors.white,
|
|
590
635
|
},
|
|
591
636
|
cardHostText: {
|
|
592
637
|
fontFamily: AppFonts_1.AppFonts.interMedium,
|
|
@@ -615,13 +660,13 @@ const getRawStyles = (colors) => ({
|
|
|
615
660
|
borderWidth: 1,
|
|
616
661
|
borderColor: `${colors.brandPurple}18`,
|
|
617
662
|
paddingHorizontal: 8,
|
|
618
|
-
paddingVertical:
|
|
663
|
+
paddingVertical: 6,
|
|
619
664
|
marginVertical: 5,
|
|
620
665
|
gap: 6,
|
|
621
666
|
},
|
|
622
667
|
slugLeft: {
|
|
623
668
|
flexDirection: 'row',
|
|
624
|
-
alignItems: '
|
|
669
|
+
alignItems: 'flex-start',
|
|
625
670
|
flex: 1,
|
|
626
671
|
gap: 6,
|
|
627
672
|
},
|
|
@@ -632,14 +677,16 @@ const getRawStyles = (colors) => ({
|
|
|
632
677
|
letterSpacing: 0.5,
|
|
633
678
|
backgroundColor: `${colors.brandPurple}15`,
|
|
634
679
|
paddingHorizontal: 4,
|
|
635
|
-
paddingVertical: 1,
|
|
680
|
+
paddingVertical: 1.5,
|
|
636
681
|
borderRadius: 4,
|
|
682
|
+
marginTop: 1,
|
|
637
683
|
},
|
|
638
684
|
slugText: {
|
|
639
|
-
fontFamily: AppFonts_1.AppFonts.
|
|
640
|
-
fontSize:
|
|
685
|
+
fontFamily: AppFonts_1.AppFonts.interMedium,
|
|
686
|
+
fontSize: 11.5,
|
|
687
|
+
lineHeight: 15.5,
|
|
641
688
|
color: colors.primaryBlack,
|
|
642
|
-
|
|
689
|
+
flex: 1,
|
|
643
690
|
},
|
|
644
691
|
slugRight: {
|
|
645
692
|
flexDirection: 'row',
|
|
@@ -102,6 +102,9 @@ export interface NetworkLog {
|
|
|
102
102
|
responseHeaders?: Record<string, string>;
|
|
103
103
|
/** #9 — number of consecutive identical requests collapsed into this entry. */
|
|
104
104
|
duplicateCount?: number;
|
|
105
|
+
/** Client identifier: axios, fetch, xhr, apollo, etc. */
|
|
106
|
+
client?: 'axios' | 'fetch' | 'xhr' | 'apollo' | 'graphql' | string;
|
|
107
|
+
caller?: string;
|
|
105
108
|
}
|
|
106
109
|
export interface RouteInfo {
|
|
107
110
|
path: string;
|
|
@@ -1,13 +1,12 @@
|
|
|
1
1
|
import React, { useState } from 'react';
|
|
2
2
|
import { Image, Platform, StyleSheet, View, } from 'react-native';
|
|
3
3
|
import BrandSquareIcon from './BrandSquareIcon';
|
|
4
|
-
import { AppColors } from '../styles/AppColors';
|
|
5
4
|
export const AppHeaderLogo = ({ size = 46, customIcon, }) => {
|
|
6
5
|
const [loadError, setLoadError] = useState(false);
|
|
7
|
-
// 1. If customIcon is explicitly provided, render it directly
|
|
6
|
+
// 1. If customIcon is explicitly provided, render it directly edge-to-edge
|
|
8
7
|
if (customIcon) {
|
|
9
8
|
return (<View style={[logoStyles.container, { width: size, height: size }]}>
|
|
10
|
-
<Image source={customIcon} style={
|
|
9
|
+
<Image source={customIcon} style={logoStyles.image} resizeMode="cover"/>
|
|
11
10
|
</View>);
|
|
12
11
|
}
|
|
13
12
|
// 2. Dynamically query installed native app icon (AppIcon on iOS, ic_launcher on Android)
|
|
@@ -18,28 +17,26 @@ export const AppHeaderLogo = ({ size = 46, customIcon, }) => {
|
|
|
18
17
|
default: { uri: 'AppIcon' },
|
|
19
18
|
});
|
|
20
19
|
return (<View style={[logoStyles.container, { width: size, height: size }]}>
|
|
21
|
-
<Image source={nativeSource} style={
|
|
20
|
+
<Image source={nativeSource} style={logoStyles.image} resizeMode="cover" onError={() => setLoadError(true)}/>
|
|
22
21
|
</View>);
|
|
23
22
|
}
|
|
24
23
|
// 3. Fallback: Inspector's Signature Owl Brand Logo
|
|
25
24
|
return (<View style={[logoStyles.container, { width: size, height: size }]}>
|
|
26
|
-
<BrandSquareIcon size={size
|
|
25
|
+
<BrandSquareIcon size={size}/>
|
|
27
26
|
</View>);
|
|
28
27
|
};
|
|
29
28
|
const logoStyles = StyleSheet.create({
|
|
30
29
|
container: {
|
|
30
|
+
borderRadius: 10,
|
|
31
|
+
overflow: 'hidden',
|
|
32
|
+
backgroundColor: 'transparent',
|
|
31
33
|
alignItems: 'center',
|
|
32
34
|
justifyContent: 'center',
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
shadowColor: AppColors.primaryBlack,
|
|
39
|
-
shadowOffset: { width: 0, height: 2 },
|
|
40
|
-
shadowOpacity: 0.15,
|
|
41
|
-
shadowRadius: 4,
|
|
42
|
-
elevation: 3,
|
|
35
|
+
},
|
|
36
|
+
image: {
|
|
37
|
+
width: '100%',
|
|
38
|
+
height: '100%',
|
|
39
|
+
borderRadius: 10,
|
|
43
40
|
},
|
|
44
41
|
});
|
|
45
42
|
export default AppHeaderLogo;
|
|
@@ -3,10 +3,10 @@ import { useTranslation } from '../i18n';
|
|
|
3
3
|
import { Pressable, StyleSheet, Text, View, } from 'react-native';
|
|
4
4
|
import { AppColors } from '../styles/AppColors';
|
|
5
5
|
import { AppFonts } from '../styles/AppFonts';
|
|
6
|
-
import { formatTime, getJsonContent, getJsonPreviewText, parseStackLine, } from '../helpers';
|
|
6
|
+
import { formatTime, getJsonContent, getJsonPreviewText, parseStackLine, openInVSCode, } from '../helpers';
|
|
7
7
|
import HighlightText from './HighlightText';
|
|
8
8
|
import CopyButton from './CopyButton';
|
|
9
|
-
import { ChevronIcon } from './NetworkIcons';
|
|
9
|
+
import { ChevronIcon, ExternalLinkIcon } from './NetworkIcons';
|
|
10
10
|
import { useInspector } from './Inspector/InspectorContext';
|
|
11
11
|
const getLogMessageWithBadges = (message, searchStr, textStyle, highlightStyle, numberOfLines) => {
|
|
12
12
|
if (!message)
|
|
@@ -226,18 +226,34 @@ export const ConsoleLogCard = React.memo(function ConsoleLogCard({ item, searchS
|
|
|
226
226
|
<Text style={styles.footerText}>{formatTime(item.timestamp)}</Text>
|
|
227
227
|
{parsedCaller && (<>
|
|
228
228
|
<View style={styles.footerDot}/>
|
|
229
|
-
<
|
|
229
|
+
<Pressable onPress={e => {
|
|
230
|
+
e.stopPropagation?.();
|
|
231
|
+
openInVSCode(parsedCaller.rawFilePath ||
|
|
232
|
+
parsedCaller.fullPath ||
|
|
233
|
+
parsedCaller.fileName, parsedCaller.lineNumber, parsedCaller.columnNumber);
|
|
234
|
+
}} hitSlop={8} style={{
|
|
235
|
+
flexDirection: 'row',
|
|
236
|
+
alignItems: 'center',
|
|
237
|
+
gap: 4,
|
|
238
|
+
maxWidth: 185,
|
|
239
|
+
backgroundColor: `${AppColors.sky600}10`,
|
|
240
|
+
borderColor: `${AppColors.sky600}2B`,
|
|
241
|
+
borderWidth: 1,
|
|
242
|
+
borderRadius: 5,
|
|
243
|
+
paddingHorizontal: 5,
|
|
244
|
+
paddingVertical: 1.5,
|
|
245
|
+
}}>
|
|
230
246
|
{parsedCaller.fileExt && parsedCaller.fileExt !== 'other' && (<View style={{
|
|
231
247
|
backgroundColor: parsedCaller.fileExt === 'tsx' || parsedCaller.fileExt === 'ts'
|
|
232
|
-
? `${AppColors.brandPurple}
|
|
233
|
-
: `${AppColors.teal600}
|
|
248
|
+
? `${AppColors.brandPurple}22`
|
|
249
|
+
: `${AppColors.teal600}22`,
|
|
234
250
|
borderRadius: 3,
|
|
235
251
|
paddingHorizontal: 3.5,
|
|
236
|
-
paddingVertical:
|
|
252
|
+
paddingVertical: 0.5,
|
|
237
253
|
}}>
|
|
238
254
|
<Text style={{
|
|
239
255
|
fontFamily: AppFonts.interBold,
|
|
240
|
-
fontSize: 8
|
|
256
|
+
fontSize: 8,
|
|
241
257
|
color: parsedCaller.fileExt === 'tsx' || parsedCaller.fileExt === 'ts'
|
|
242
258
|
? AppColors.brandPurple
|
|
243
259
|
: AppColors.teal600,
|
|
@@ -245,11 +261,19 @@ export const ConsoleLogCard = React.memo(function ConsoleLogCard({ item, searchS
|
|
|
245
261
|
{parsedCaller.fileExt.toUpperCase()}
|
|
246
262
|
</Text>
|
|
247
263
|
</View>)}
|
|
248
|
-
<Text style={[
|
|
264
|
+
<Text style={[
|
|
265
|
+
styles.footerText,
|
|
266
|
+
{
|
|
267
|
+
fontFamily: AppFonts.interBold,
|
|
268
|
+
color: AppColors.sky600,
|
|
269
|
+
fontSize: 9.5,
|
|
270
|
+
},
|
|
271
|
+
]} numberOfLines={1} ellipsizeMode="middle">
|
|
249
272
|
{parsedCaller.fileName}
|
|
250
273
|
{parsedCaller.lineNumber ? `:${parsedCaller.lineNumber}` : ''}
|
|
251
274
|
</Text>
|
|
252
|
-
|
|
275
|
+
<ExternalLinkIcon color={AppColors.sky600} size={8.5}/>
|
|
276
|
+
</Pressable>
|
|
253
277
|
</>)}
|
|
254
278
|
</View>
|
|
255
279
|
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import React, { useState, useCallback } from 'react';
|
|
2
|
+
import { Share } from 'react-native';
|
|
2
3
|
// Components
|
|
3
4
|
import TouchableScale from './TouchableScale';
|
|
4
5
|
// Helpers
|
|
@@ -16,6 +17,19 @@ const CopyButton = React.memo(({ value, label, iconType = 'copy' }) => {
|
|
|
16
17
|
setCopied(true);
|
|
17
18
|
setTimeout(() => setCopied(false), 1200);
|
|
18
19
|
}, [value, label]);
|
|
20
|
+
const handleLongPress = useCallback(() => {
|
|
21
|
+
try {
|
|
22
|
+
const resolvedValue = typeof value === 'function' ? value() : value;
|
|
23
|
+
const textToShare = typeof resolvedValue === 'string'
|
|
24
|
+
? resolvedValue
|
|
25
|
+
: JSON.stringify(resolvedValue, null, 2);
|
|
26
|
+
Share.share({
|
|
27
|
+
message: textToShare,
|
|
28
|
+
title: label,
|
|
29
|
+
});
|
|
30
|
+
}
|
|
31
|
+
catch { }
|
|
32
|
+
}, [value, label]);
|
|
19
33
|
const containerStyle = [
|
|
20
34
|
styles.iconSquareBtn,
|
|
21
35
|
copied && styles.iconSquareBtnSuccess,
|
|
@@ -25,7 +39,7 @@ const CopyButton = React.memo(({ value, label, iconType = 'copy' }) => {
|
|
|
25
39
|
: iconType === 'fetch'
|
|
26
40
|
? FetchIcon
|
|
27
41
|
: CopyIcon;
|
|
28
|
-
return (<TouchableScale onPress={handlePress} hitSlop={12} style={containerStyle}>
|
|
42
|
+
return (<TouchableScale onPress={handlePress} onLongPress={handleLongPress} hitSlop={12} style={containerStyle}>
|
|
29
43
|
{copied ? (<CheckIcon color={AppColors.greenColor} size={14}/>) : (<IconComponent color={AppColors.grayTextWeak} size={14}/>)}
|
|
30
44
|
</TouchableScale>);
|
|
31
45
|
});
|