react-native-inapp-inspector 2.3.5 → 2.3.6
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/dist/commonjs/analytics.d.ts +0 -4
- package/dist/commonjs/analytics.js +0 -4
- package/dist/commonjs/bundle.d.ts +0 -4
- package/dist/commonjs/bundle.js +0 -4
- package/dist/commonjs/components/AnalyticsDetail.js +18 -27
- package/dist/commonjs/components/AnalyticsEventCard.js +9 -12
- package/dist/commonjs/components/AnalyticsGraph.js +10 -15
- package/dist/commonjs/components/AppHeaderLogo.js +0 -3
- package/dist/commonjs/components/BrandCircleIcon.js +15 -15
- package/dist/commonjs/components/BrandSquareIcon.js +20 -20
- package/dist/commonjs/components/CodeSnippet.js +6 -19
- package/dist/commonjs/components/ConsoleLogCard.js +0 -1
- package/dist/commonjs/components/CopyButton.js +0 -4
- package/dist/commonjs/components/DiffViewer.js +0 -2
- package/dist/commonjs/components/DomainHeader.js +0 -4
- package/dist/commonjs/components/EmptyState.js +0 -3
- package/dist/commonjs/components/ErrorBoundary.js +5 -10
- package/dist/commonjs/components/HeadersSection.js +0 -5
- package/dist/commonjs/components/HighlightText.js +1 -4
- package/dist/commonjs/components/Inspector/AnalyticsFilterModal.js +11 -26
- package/dist/commonjs/components/Inspector/AnalyticsTab.js +34 -40
- package/dist/commonjs/components/Inspector/BundleTab.js +56 -84
- package/dist/commonjs/components/Inspector/ConsoleTab.js +7 -7
- package/dist/commonjs/components/Inspector/CrashDetail.js +18 -20
- package/dist/commonjs/components/Inspector/CrashFilterModal.js +0 -1
- package/dist/commonjs/components/Inspector/CrashTab.js +11 -20
- package/dist/commonjs/components/Inspector/DeviceInfoTab.js +12 -24
- package/dist/commonjs/components/Inspector/FabLauncher.js +1 -1
- package/dist/commonjs/components/Inspector/InspectorContext.js +0 -2
- package/dist/commonjs/components/Inspector/InspectorHeader.js +7 -8
- package/dist/commonjs/components/Inspector/LogDetail.js +27 -29
- package/dist/commonjs/components/Inspector/MainScreen.js +9 -10
- package/dist/commonjs/components/Inspector/NetworkDetail.js +10 -11
- package/dist/commonjs/components/Inspector/NetworkTab.js +14 -14
- package/dist/commonjs/components/Inspector/NpmUpdateToast.js +6 -9
- package/dist/commonjs/components/Inspector/PerformanceTab.js +30 -43
- package/dist/commonjs/components/Inspector/ReduxDetail.js +18 -34
- package/dist/commonjs/components/Inspector/ReduxTab.js +11 -20
- package/dist/commonjs/components/Inspector/SettingsPanel.js +32 -36
- package/dist/commonjs/components/Inspector/SkeletonPlaceholder.js +6 -6
- package/dist/commonjs/components/Inspector/StorageTab.js +14 -26
- package/dist/commonjs/components/Inspector/UpdateAvailableModal.js +5 -6
- package/dist/commonjs/components/JsonViewer.js +3 -10
- package/dist/commonjs/components/LogCard.js +7 -7
- package/dist/commonjs/components/MetaAccordion.js +1 -7
- package/dist/commonjs/components/NetworkIcons.js +12 -16
- package/dist/commonjs/components/SectionHeader.js +0 -4
- package/dist/commonjs/components/SkeletonPlaceholder.js +6 -6
- package/dist/commonjs/components/Slider.js +6 -6
- package/dist/commonjs/components/SourcePageCard.js +0 -4
- package/dist/commonjs/components/TreeNode.js +0 -4
- package/dist/commonjs/console.d.ts +0 -4
- package/dist/commonjs/console.js +0 -4
- package/dist/commonjs/constants/index.js +6 -9
- package/dist/commonjs/constants/telemetryConfig.d.ts +7 -0
- package/dist/commonjs/constants/telemetryConfig.js +10 -0
- package/dist/commonjs/constants/version.d.ts +1 -1
- package/dist/commonjs/constants/version.js +1 -3
- package/dist/commonjs/crash.d.ts +0 -4
- package/dist/commonjs/crash.js +0 -4
- package/dist/commonjs/customHooks/analyticsLogger.d.ts +0 -7
- package/dist/commonjs/customHooks/analyticsLogger.js +3 -59
- package/dist/commonjs/customHooks/bundleAnalyzer.d.ts +0 -9
- package/dist/commonjs/customHooks/bundleAnalyzer.js +3 -86
- package/dist/commonjs/customHooks/consoleLogger.js +0 -16
- package/dist/commonjs/customHooks/crashHandler.d.ts +0 -28
- package/dist/commonjs/customHooks/crashHandler.js +0 -55
- package/dist/commonjs/customHooks/logFilters.d.ts +0 -4
- package/dist/commonjs/customHooks/logFilters.js +0 -11
- package/dist/commonjs/customHooks/networkLogger.js +2 -13
- package/dist/commonjs/customHooks/performanceTracker.d.ts +0 -27
- package/dist/commonjs/customHooks/performanceTracker.js +0 -31
- package/dist/commonjs/customHooks/reduxLogger.d.ts +0 -12
- package/dist/commonjs/customHooks/reduxLogger.js +0 -51
- package/dist/commonjs/customHooks/storageInspector.d.ts +0 -40
- package/dist/commonjs/customHooks/storageInspector.js +1 -56
- package/dist/commonjs/decorators/index.d.ts +0 -37
- package/dist/commonjs/decorators/index.js +0 -42
- package/dist/commonjs/helpers/gaAnalyticsRegistry.d.ts +0 -10
- package/dist/commonjs/helpers/gaAnalyticsRegistry.js +0 -26
- package/dist/commonjs/helpers/index.d.ts +0 -7
- package/dist/commonjs/helpers/index.js +1 -42
- package/dist/commonjs/helpers/memoryManager.d.ts +0 -11
- package/dist/commonjs/helpers/memoryManager.js +0 -13
- package/dist/commonjs/helpers/searchQueryParser.d.ts +0 -4
- package/dist/commonjs/helpers/searchQueryParser.js +0 -18
- package/dist/commonjs/helpers/settingsStore.js +0 -8
- package/dist/commonjs/helpers/telemetry.d.ts +2 -0
- package/dist/commonjs/helpers/telemetry.js +302 -0
- package/dist/commonjs/i18n/index.d.ts +0 -9
- package/dist/commonjs/i18n/index.js +0 -15
- package/dist/commonjs/index.js +15 -97
- package/dist/commonjs/native/NativeInspector.d.ts +0 -54
- package/dist/commonjs/native/NativeInspector.js +0 -56
- package/dist/commonjs/network.d.ts +0 -4
- package/dist/commonjs/network.js +0 -4
- package/dist/commonjs/performance.d.ts +0 -4
- package/dist/commonjs/performance.js +0 -4
- package/dist/commonjs/redux.d.ts +0 -4
- package/dist/commonjs/redux.js +0 -4
- package/dist/commonjs/storage.d.ts +0 -4
- package/dist/commonjs/storage.js +0 -4
- package/dist/commonjs/styles/AppColors.d.ts +0 -3
- package/dist/commonjs/styles/AppColors.js +15 -30
- package/dist/commonjs/styles/AppFonts.d.ts +0 -4
- package/dist/commonjs/styles/AppFonts.js +0 -4
- package/dist/commonjs/styles/common.js +0 -11
- package/dist/commonjs/styles/index.js +0 -8
- package/dist/commonjs/types/enums.js +0 -3
- package/dist/commonjs/types/interfaces.d.ts +3 -3
- package/dist/esm/analytics.d.ts +0 -4
- package/dist/esm/analytics.js +0 -4
- package/dist/esm/bundle.d.ts +0 -4
- package/dist/esm/bundle.js +0 -4
- package/dist/esm/components/AnalyticsDetail.js +18 -27
- package/dist/esm/components/AnalyticsEventCard.js +9 -12
- package/dist/esm/components/AnalyticsGraph.js +10 -15
- package/dist/esm/components/AppHeaderLogo.js +0 -3
- package/dist/esm/components/BrandCircleIcon.js +15 -15
- package/dist/esm/components/BrandSquareIcon.js +20 -20
- package/dist/esm/components/CodeSnippet.js +6 -19
- package/dist/esm/components/ConsoleLogCard.js +0 -1
- package/dist/esm/components/CopyButton.js +0 -4
- package/dist/esm/components/DiffViewer.js +0 -2
- package/dist/esm/components/DomainHeader.js +0 -4
- package/dist/esm/components/EmptyState.js +0 -3
- package/dist/esm/components/ErrorBoundary.js +5 -10
- package/dist/esm/components/HeadersSection.js +0 -5
- package/dist/esm/components/HighlightText.js +1 -4
- package/dist/esm/components/Inspector/AnalyticsFilterModal.js +11 -26
- package/dist/esm/components/Inspector/AnalyticsTab.js +34 -40
- package/dist/esm/components/Inspector/BundleTab.js +56 -84
- package/dist/esm/components/Inspector/ConsoleTab.js +7 -7
- package/dist/esm/components/Inspector/CrashDetail.js +18 -20
- package/dist/esm/components/Inspector/CrashFilterModal.js +0 -1
- package/dist/esm/components/Inspector/CrashTab.js +11 -20
- package/dist/esm/components/Inspector/DeviceInfoTab.js +12 -24
- package/dist/esm/components/Inspector/FabLauncher.js +1 -1
- package/dist/esm/components/Inspector/InspectorContext.js +0 -2
- package/dist/esm/components/Inspector/InspectorHeader.js +7 -8
- package/dist/esm/components/Inspector/LogDetail.js +27 -29
- package/dist/esm/components/Inspector/MainScreen.js +9 -10
- package/dist/esm/components/Inspector/NetworkDetail.js +10 -11
- package/dist/esm/components/Inspector/NetworkTab.js +14 -14
- package/dist/esm/components/Inspector/NpmUpdateToast.js +6 -9
- package/dist/esm/components/Inspector/PerformanceTab.js +30 -43
- package/dist/esm/components/Inspector/ReduxDetail.js +18 -34
- package/dist/esm/components/Inspector/ReduxTab.js +11 -20
- package/dist/esm/components/Inspector/SettingsPanel.js +32 -36
- package/dist/esm/components/Inspector/SkeletonPlaceholder.js +6 -6
- package/dist/esm/components/Inspector/StorageTab.js +14 -26
- package/dist/esm/components/Inspector/UpdateAvailableModal.js +5 -6
- package/dist/esm/components/JsonViewer.js +3 -10
- package/dist/esm/components/LogCard.js +7 -7
- package/dist/esm/components/MetaAccordion.js +1 -7
- package/dist/esm/components/NetworkIcons.js +12 -16
- package/dist/esm/components/SectionHeader.js +0 -4
- package/dist/esm/components/SkeletonPlaceholder.js +6 -6
- package/dist/esm/components/Slider.js +6 -6
- package/dist/esm/components/SourcePageCard.js +0 -4
- package/dist/esm/components/TreeNode.js +0 -4
- package/dist/esm/console.d.ts +0 -4
- package/dist/esm/console.js +0 -4
- package/dist/esm/constants/index.js +6 -9
- package/dist/esm/constants/telemetryConfig.d.ts +7 -0
- package/dist/esm/constants/telemetryConfig.js +7 -0
- package/dist/esm/constants/version.d.ts +1 -1
- package/dist/esm/constants/version.js +1 -3
- package/dist/esm/crash.d.ts +0 -4
- package/dist/esm/crash.js +0 -4
- package/dist/esm/customHooks/analyticsLogger.d.ts +0 -7
- package/dist/esm/customHooks/analyticsLogger.js +3 -59
- package/dist/esm/customHooks/bundleAnalyzer.d.ts +0 -9
- package/dist/esm/customHooks/bundleAnalyzer.js +3 -86
- package/dist/esm/customHooks/consoleLogger.js +0 -16
- package/dist/esm/customHooks/crashHandler.d.ts +0 -28
- package/dist/esm/customHooks/crashHandler.js +0 -55
- package/dist/esm/customHooks/logFilters.d.ts +0 -4
- package/dist/esm/customHooks/logFilters.js +0 -11
- package/dist/esm/customHooks/networkLogger.js +2 -13
- package/dist/esm/customHooks/performanceTracker.d.ts +0 -27
- package/dist/esm/customHooks/performanceTracker.js +0 -31
- package/dist/esm/customHooks/reduxLogger.d.ts +0 -12
- package/dist/esm/customHooks/reduxLogger.js +0 -51
- package/dist/esm/customHooks/storageInspector.d.ts +0 -40
- package/dist/esm/customHooks/storageInspector.js +1 -56
- package/dist/esm/decorators/index.d.ts +0 -37
- package/dist/esm/decorators/index.js +0 -42
- package/dist/esm/helpers/gaAnalyticsRegistry.d.ts +0 -10
- package/dist/esm/helpers/gaAnalyticsRegistry.js +0 -26
- package/dist/esm/helpers/index.d.ts +0 -7
- package/dist/esm/helpers/index.js +1 -42
- package/dist/esm/helpers/memoryManager.d.ts +0 -11
- package/dist/esm/helpers/memoryManager.js +0 -13
- package/dist/esm/helpers/searchQueryParser.d.ts +0 -4
- package/dist/esm/helpers/searchQueryParser.js +0 -18
- package/dist/esm/helpers/settingsStore.js +0 -8
- package/dist/esm/helpers/telemetry.d.ts +2 -0
- package/dist/esm/helpers/telemetry.js +298 -0
- package/dist/esm/i18n/index.d.ts +0 -9
- package/dist/esm/i18n/index.js +0 -15
- package/dist/esm/index.js +15 -97
- package/dist/esm/native/NativeInspector.d.ts +0 -54
- package/dist/esm/native/NativeInspector.js +0 -56
- package/dist/esm/network.d.ts +0 -4
- package/dist/esm/network.js +0 -4
- package/dist/esm/performance.d.ts +0 -4
- package/dist/esm/performance.js +0 -4
- package/dist/esm/redux.d.ts +0 -4
- package/dist/esm/redux.js +0 -4
- package/dist/esm/storage.d.ts +0 -4
- package/dist/esm/storage.js +0 -4
- package/dist/esm/styles/AppColors.d.ts +0 -3
- package/dist/esm/styles/AppColors.js +15 -30
- package/dist/esm/styles/AppFonts.d.ts +0 -4
- package/dist/esm/styles/AppFonts.js +0 -4
- package/dist/esm/styles/common.js +0 -11
- package/dist/esm/styles/index.js +0 -8
- package/dist/esm/types/enums.js +0 -3
- package/dist/esm/types/interfaces.d.ts +3 -3
- package/package.json +2 -2
- package/src/constants/telemetryConfig.ts +16 -0
- package/src/constants/version.ts +1 -1
- package/src/helpers/telemetry.ts +341 -0
- package/src/index.tsx +15 -1
- package/src/types/interfaces.ts +3 -0
|
@@ -32,75 +32,31 @@ export interface NativeCrashEvent {
|
|
|
32
32
|
timestamp: number;
|
|
33
33
|
}
|
|
34
34
|
export declare const isNativeModuleAvailable: () => boolean;
|
|
35
|
-
/**
|
|
36
|
-
* Retrieves low-level native hardware and system metrics (RAM, Heap, Disk, Battery, CPU).
|
|
37
|
-
*/
|
|
38
35
|
export declare const getNativeDeviceMetrics: () => Promise<NativeDeviceMetrics | null>;
|
|
39
|
-
/**
|
|
40
|
-
* Enables native signal and uncaught exception protection in the iOS / Android runtime.
|
|
41
|
-
* Automatically ensures the native floating icon is shown and available before UI renders.
|
|
42
|
-
*/
|
|
43
36
|
export declare const enableNativeCrashProtection: (options?: {
|
|
44
37
|
showFloatingButton?: boolean;
|
|
45
38
|
}) => Promise<boolean>;
|
|
46
|
-
/**
|
|
47
|
-
* Subscribes to fatal native crash events caught by the iOS / Kotlin exception handlers.
|
|
48
|
-
*/
|
|
49
39
|
export declare const subscribeNativeCrashes: (callback: (event: NativeCrashEvent) => void) => (() => void);
|
|
50
40
|
export interface FloatingButtonOptions {
|
|
51
41
|
size?: number;
|
|
52
42
|
x?: number;
|
|
53
43
|
y?: number;
|
|
54
44
|
}
|
|
55
|
-
/**
|
|
56
|
-
* Displays the 100% native main-thread floating overlay button.
|
|
57
|
-
* Dragging & touches run on the native UI thread, completely isolated from JS thread stalls.
|
|
58
|
-
*/
|
|
59
45
|
export declare const showNativeFloatingButton: (options?: FloatingButtonOptions) => Promise<boolean>;
|
|
60
|
-
/**
|
|
61
|
-
* Hides the native floating overlay button.
|
|
62
|
-
*/
|
|
63
46
|
export declare const hideNativeFloatingButton: () => Promise<boolean>;
|
|
64
|
-
/**
|
|
65
|
-
* Updates the badge/status dot on the native floating overlay button.
|
|
66
|
-
*/
|
|
67
47
|
export declare const setNativeFloatingButtonBadge: (hasBadge: boolean) => Promise<boolean>;
|
|
68
|
-
/**
|
|
69
|
-
* Subscribes to tap events on the native floating button.
|
|
70
|
-
*/
|
|
71
48
|
export declare const subscribeNativeFloatingButtonPress: (callback: () => void) => (() => void);
|
|
72
|
-
/**
|
|
73
|
-
* Starts hardware-accurate native UI thread FPS tracking (CADisplayLink / Choreographer).
|
|
74
|
-
*/
|
|
75
49
|
export declare const startNativeFpsMonitoring: () => Promise<boolean>;
|
|
76
|
-
/**
|
|
77
|
-
* Stops native FPS tracking.
|
|
78
|
-
*/
|
|
79
50
|
export declare const stopNativeFpsMonitoring: () => Promise<boolean>;
|
|
80
51
|
export interface NativeFpsMetrics {
|
|
81
52
|
fps: number;
|
|
82
53
|
targetFps: number;
|
|
83
54
|
}
|
|
84
|
-
/**
|
|
85
|
-
* Reads the latest live hardware FPS from CADisplayLink (iOS) or Choreographer (Android).
|
|
86
|
-
*/
|
|
87
55
|
export declare const getNativeFpsMetrics: () => Promise<NativeFpsMetrics>;
|
|
88
|
-
/**
|
|
89
|
-
* Subscribes to physical hardware shake events (or Cmd+Ctrl+Z on iOS simulator).
|
|
90
|
-
*/
|
|
91
56
|
export declare const subscribeNativeDeviceShake: (callback: () => void) => (() => void);
|
|
92
|
-
/**
|
|
93
|
-
* Reads a persisted value synchronously from native NSUserDefaults / SharedPreferences.
|
|
94
|
-
*/
|
|
95
57
|
export declare const getNativeStorageItem: (key: string) => Promise<string | null>;
|
|
96
|
-
/**
|
|
97
|
-
* Persists a key-value pair to native NSUserDefaults / SharedPreferences with 0ms latency.
|
|
98
|
-
*/
|
|
99
58
|
export declare const setNativeStorageItem: (key: string, value: string | null) => Promise<boolean>;
|
|
100
59
|
export type HapticStyle = 'light' | 'medium' | 'heavy' | 'success' | 'warning' | 'error';
|
|
101
|
-
/**
|
|
102
|
-
* Triggers hardware native haptic feedback (iOS UIFeedbackGenerator / Android VibrationEffect).
|
|
103
|
-
*/
|
|
104
60
|
export declare const triggerNativeHaptic: (style?: HapticStyle) => Promise<boolean>;
|
|
105
61
|
export interface NativeSystemMetrics {
|
|
106
62
|
thermalState: 'nominal' | 'fair' | 'serious' | 'critical';
|
|
@@ -109,13 +65,7 @@ export interface NativeSystemMetrics {
|
|
|
109
65
|
fps: number;
|
|
110
66
|
activeCpuCores: number;
|
|
111
67
|
}
|
|
112
|
-
/**
|
|
113
|
-
* Retrieves live system thermal state and RAM telemetry directly from native layer.
|
|
114
|
-
*/
|
|
115
68
|
export declare const getNativeSystemMetrics: () => Promise<NativeSystemMetrics | null>;
|
|
116
|
-
/**
|
|
117
|
-
* Pushes a log payload to native background worker queues for instant native page caching.
|
|
118
|
-
*/
|
|
119
69
|
export declare const pushNativeLogRecord: (pageKey: "apis" | "logs" | "analytics" | "crash", jsonPayload: string) => Promise<boolean>;
|
|
120
70
|
export interface NativeCachedPageResult<T = any> {
|
|
121
71
|
pageKey: string;
|
|
@@ -123,8 +73,4 @@ export interface NativeCachedPageResult<T = any> {
|
|
|
123
73
|
offset: number;
|
|
124
74
|
items: T[];
|
|
125
75
|
}
|
|
126
|
-
/**
|
|
127
|
-
* Fetches pre-indexed, pre-sliced page data directly from native background memory queues.
|
|
128
|
-
* Delivers instantaneous 0ms page loading without blocking JS render thread.
|
|
129
|
-
*/
|
|
130
76
|
export declare const fetchNativeCachedPage: <T = any>(pageKey: "apis" | "logs" | "analytics" | "crash", offset?: number, limit?: number, query?: string) => Promise<NativeCachedPageResult<T> | null>;
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { NativeModules, NativeEventEmitter, DeviceEventEmitter, } from 'react-native';
|
|
2
2
|
import NativeNetworkInspector from './NativeNetworkInspector';
|
|
3
|
-
// Seamless TurboModule (New Architecture / JSI) & Legacy NativeModules Bridge resolution
|
|
4
3
|
const NativeModule = NativeNetworkInspector || NativeModules.NetworkInspectorModule;
|
|
5
4
|
export const isNativeModuleAvailable = () => {
|
|
6
5
|
return !!NativeModule;
|
|
@@ -15,9 +14,6 @@ const getNativeEmitter = () => {
|
|
|
15
14
|
return null;
|
|
16
15
|
};
|
|
17
16
|
const nativeEmitter = getNativeEmitter();
|
|
18
|
-
/**
|
|
19
|
-
* Retrieves low-level native hardware and system metrics (RAM, Heap, Disk, Battery, CPU).
|
|
20
|
-
*/
|
|
21
17
|
export const getNativeDeviceMetrics = async () => {
|
|
22
18
|
if (!NativeModule || !NativeModule.getDeviceMetrics) {
|
|
23
19
|
return null;
|
|
@@ -30,10 +26,6 @@ export const getNativeDeviceMetrics = async () => {
|
|
|
30
26
|
return null;
|
|
31
27
|
}
|
|
32
28
|
};
|
|
33
|
-
/**
|
|
34
|
-
* Enables native signal and uncaught exception protection in the iOS / Android runtime.
|
|
35
|
-
* Automatically ensures the native floating icon is shown and available before UI renders.
|
|
36
|
-
*/
|
|
37
29
|
export const enableNativeCrashProtection = async (options) => {
|
|
38
30
|
if (!NativeModule || !NativeModule.enableNativeCrashProtection) {
|
|
39
31
|
return false;
|
|
@@ -49,9 +41,6 @@ export const enableNativeCrashProtection = async (options) => {
|
|
|
49
41
|
return false;
|
|
50
42
|
}
|
|
51
43
|
};
|
|
52
|
-
/**
|
|
53
|
-
* Subscribes to fatal native crash events caught by the iOS / Kotlin exception handlers.
|
|
54
|
-
*/
|
|
55
44
|
export const subscribeNativeCrashes = (callback) => {
|
|
56
45
|
const cleanups = [];
|
|
57
46
|
try {
|
|
@@ -75,10 +64,6 @@ export const subscribeNativeCrashes = (callback) => {
|
|
|
75
64
|
});
|
|
76
65
|
};
|
|
77
66
|
};
|
|
78
|
-
/**
|
|
79
|
-
* Displays the 100% native main-thread floating overlay button.
|
|
80
|
-
* Dragging & touches run on the native UI thread, completely isolated from JS thread stalls.
|
|
81
|
-
*/
|
|
82
67
|
export const showNativeFloatingButton = async (options) => {
|
|
83
68
|
if (!NativeModule || !NativeModule.showFloatingButton) {
|
|
84
69
|
return false;
|
|
@@ -91,9 +76,6 @@ export const showNativeFloatingButton = async (options) => {
|
|
|
91
76
|
return false;
|
|
92
77
|
}
|
|
93
78
|
};
|
|
94
|
-
/**
|
|
95
|
-
* Hides the native floating overlay button.
|
|
96
|
-
*/
|
|
97
79
|
export const hideNativeFloatingButton = async () => {
|
|
98
80
|
if (!NativeModule || !NativeModule.hideFloatingButton) {
|
|
99
81
|
return false;
|
|
@@ -106,9 +88,6 @@ export const hideNativeFloatingButton = async () => {
|
|
|
106
88
|
return false;
|
|
107
89
|
}
|
|
108
90
|
};
|
|
109
|
-
/**
|
|
110
|
-
* Updates the badge/status dot on the native floating overlay button.
|
|
111
|
-
*/
|
|
112
91
|
export const setNativeFloatingButtonBadge = async (hasBadge) => {
|
|
113
92
|
if (!NativeModule || !NativeModule.setFloatingButtonBadge) {
|
|
114
93
|
return false;
|
|
@@ -121,9 +100,6 @@ export const setNativeFloatingButtonBadge = async (hasBadge) => {
|
|
|
121
100
|
return false;
|
|
122
101
|
}
|
|
123
102
|
};
|
|
124
|
-
/**
|
|
125
|
-
* Subscribes to tap events on the native floating button.
|
|
126
|
-
*/
|
|
127
103
|
export const subscribeNativeFloatingButtonPress = (callback) => {
|
|
128
104
|
const cleanups = [];
|
|
129
105
|
try {
|
|
@@ -138,7 +114,6 @@ export const subscribeNativeFloatingButtonPress = (callback) => {
|
|
|
138
114
|
}
|
|
139
115
|
catch (e) { }
|
|
140
116
|
}
|
|
141
|
-
// Active Bridgeless / TurboModule tap detection
|
|
142
117
|
const interval = setInterval(async () => {
|
|
143
118
|
if (NativeModule && NativeModule.checkFloatingButtonPress) {
|
|
144
119
|
try {
|
|
@@ -160,9 +135,6 @@ export const subscribeNativeFloatingButtonPress = (callback) => {
|
|
|
160
135
|
});
|
|
161
136
|
};
|
|
162
137
|
};
|
|
163
|
-
/**
|
|
164
|
-
* Starts hardware-accurate native UI thread FPS tracking (CADisplayLink / Choreographer).
|
|
165
|
-
*/
|
|
166
138
|
export const startNativeFpsMonitoring = async () => {
|
|
167
139
|
if (!NativeModule || !NativeModule.startFpsMonitoring) {
|
|
168
140
|
return false;
|
|
@@ -175,9 +147,6 @@ export const startNativeFpsMonitoring = async () => {
|
|
|
175
147
|
return false;
|
|
176
148
|
}
|
|
177
149
|
};
|
|
178
|
-
/**
|
|
179
|
-
* Stops native FPS tracking.
|
|
180
|
-
*/
|
|
181
150
|
export const stopNativeFpsMonitoring = async () => {
|
|
182
151
|
if (!NativeModule || !NativeModule.stopFpsMonitoring) {
|
|
183
152
|
return false;
|
|
@@ -190,9 +159,6 @@ export const stopNativeFpsMonitoring = async () => {
|
|
|
190
159
|
return false;
|
|
191
160
|
}
|
|
192
161
|
};
|
|
193
|
-
/**
|
|
194
|
-
* Reads the latest live hardware FPS from CADisplayLink (iOS) or Choreographer (Android).
|
|
195
|
-
*/
|
|
196
162
|
export const getNativeFpsMetrics = async () => {
|
|
197
163
|
if (!NativeModule || !NativeModule.getFpsMetrics) {
|
|
198
164
|
return { fps: 60, targetFps: 60 };
|
|
@@ -208,9 +174,6 @@ export const getNativeFpsMetrics = async () => {
|
|
|
208
174
|
return { fps: 60, targetFps: 60 };
|
|
209
175
|
}
|
|
210
176
|
};
|
|
211
|
-
/**
|
|
212
|
-
* Subscribes to physical hardware shake events (or Cmd+Ctrl+Z on iOS simulator).
|
|
213
|
-
*/
|
|
214
177
|
export const subscribeNativeDeviceShake = (callback) => {
|
|
215
178
|
if (!nativeEmitter) {
|
|
216
179
|
return () => { };
|
|
@@ -225,9 +188,6 @@ export const subscribeNativeDeviceShake = (callback) => {
|
|
|
225
188
|
return () => { };
|
|
226
189
|
}
|
|
227
190
|
};
|
|
228
|
-
/**
|
|
229
|
-
* Reads a persisted value synchronously from native NSUserDefaults / SharedPreferences.
|
|
230
|
-
*/
|
|
231
191
|
export const getNativeStorageItem = async (key) => {
|
|
232
192
|
if (!NativeModule || !NativeModule.getNativeStorageItem) {
|
|
233
193
|
return null;
|
|
@@ -240,9 +200,6 @@ export const getNativeStorageItem = async (key) => {
|
|
|
240
200
|
return null;
|
|
241
201
|
}
|
|
242
202
|
};
|
|
243
|
-
/**
|
|
244
|
-
* Persists a key-value pair to native NSUserDefaults / SharedPreferences with 0ms latency.
|
|
245
|
-
*/
|
|
246
203
|
export const setNativeStorageItem = async (key, value) => {
|
|
247
204
|
if (!NativeModule || !NativeModule.setNativeStorageItem) {
|
|
248
205
|
return false;
|
|
@@ -255,9 +212,6 @@ export const setNativeStorageItem = async (key, value) => {
|
|
|
255
212
|
return false;
|
|
256
213
|
}
|
|
257
214
|
};
|
|
258
|
-
/**
|
|
259
|
-
* Triggers hardware native haptic feedback (iOS UIFeedbackGenerator / Android VibrationEffect).
|
|
260
|
-
*/
|
|
261
215
|
export const triggerNativeHaptic = async (style = 'light') => {
|
|
262
216
|
if (!NativeModule || !NativeModule.triggerHaptic) {
|
|
263
217
|
return false;
|
|
@@ -270,9 +224,6 @@ export const triggerNativeHaptic = async (style = 'light') => {
|
|
|
270
224
|
return false;
|
|
271
225
|
}
|
|
272
226
|
};
|
|
273
|
-
/**
|
|
274
|
-
* Retrieves live system thermal state and RAM telemetry directly from native layer.
|
|
275
|
-
*/
|
|
276
227
|
export const getNativeSystemMetrics = async () => {
|
|
277
228
|
if (!NativeModule || !NativeModule.getNativeSystemMetrics) {
|
|
278
229
|
return null;
|
|
@@ -285,9 +236,6 @@ export const getNativeSystemMetrics = async () => {
|
|
|
285
236
|
return null;
|
|
286
237
|
}
|
|
287
238
|
};
|
|
288
|
-
/**
|
|
289
|
-
* Pushes a log payload to native background worker queues for instant native page caching.
|
|
290
|
-
*/
|
|
291
239
|
export const pushNativeLogRecord = async (pageKey, jsonPayload) => {
|
|
292
240
|
if (!NativeModule || !NativeModule.pushNativeLogRecord) {
|
|
293
241
|
return false;
|
|
@@ -300,10 +248,6 @@ export const pushNativeLogRecord = async (pageKey, jsonPayload) => {
|
|
|
300
248
|
return false;
|
|
301
249
|
}
|
|
302
250
|
};
|
|
303
|
-
/**
|
|
304
|
-
* Fetches pre-indexed, pre-sliced page data directly from native background memory queues.
|
|
305
|
-
* Delivers instantaneous 0ms page loading without blocking JS render thread.
|
|
306
|
-
*/
|
|
307
251
|
export const fetchNativeCachedPage = async (pageKey, offset = 0, limit = 50, query = '') => {
|
|
308
252
|
if (!NativeModule || !NativeModule.getNativeCachedPage) {
|
|
309
253
|
return null;
|
package/dist/esm/network.d.ts
CHANGED
|
@@ -1,6 +1,2 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Sub-module entry point: react-native-inapp-inspector/network
|
|
3
|
-
* Clean tree-shaking & isolated network logger without UI or React Context dependencies.
|
|
4
|
-
*/
|
|
5
1
|
export { setupNetworkLogger, clearNetworkLogs, subscribeNetworkLogs, getNetworkLogs, setNetworkModuleEnabled, getNetworkModuleEnabled, setMaxNetworkLogsLimit, getMaxNetworkLogsLimit, pruneNetworkLogs, } from './customHooks/networkLogger';
|
|
6
2
|
export type { NetworkLog, Method, StatusFilter, SortOrder, } from './types';
|
package/dist/esm/network.js
CHANGED
|
@@ -1,5 +1 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Sub-module entry point: react-native-inapp-inspector/network
|
|
3
|
-
* Clean tree-shaking & isolated network logger without UI or React Context dependencies.
|
|
4
|
-
*/
|
|
5
1
|
export { setupNetworkLogger, clearNetworkLogs, subscribeNetworkLogs, getNetworkLogs, setNetworkModuleEnabled, getNetworkModuleEnabled, setMaxNetworkLogsLimit, getMaxNetworkLogsLimit, pruneNetworkLogs, } from './customHooks/networkLogger';
|
|
@@ -1,6 +1,2 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Sub-module entry point: react-native-inapp-inspector/performance
|
|
3
|
-
* Clean tree-shaking & isolated performance tracker and profiler.
|
|
4
|
-
*/
|
|
5
1
|
export { usePerformanceTracker, useComponentProfiler, useNavigationProfiler, trackComponentRender, trackNavigationTransition, trackHeavyTask, measureAsync, getHermesMemoryStats, registerComponentProfile, subscribeRenderProfiles, getRenderProfiles, logPerformanceEvent, clearPerformanceEvents, subscribePerformanceEvents, getPerformanceEvents, getInitialRenderProfiles, getInitialPerformanceEvents, generateFixSnippet, setPerformanceModuleEnabled, getPerformanceModuleEnabled, setMaxPerformanceEventsLimit, getMaxPerformanceEventsLimit, prunePerformanceEvents, type PerformanceEvent, type LiveMemoryStats, type ComponentRenderProfile, type CoreMobileVitals, type PerformanceFixKey, } from './customHooks/performanceTracker';
|
|
6
2
|
export { PerformanceSubTab, } from './types';
|
package/dist/esm/performance.js
CHANGED
|
@@ -1,6 +1,2 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Sub-module entry point: react-native-inapp-inspector/performance
|
|
3
|
-
* Clean tree-shaking & isolated performance tracker and profiler.
|
|
4
|
-
*/
|
|
5
1
|
export { usePerformanceTracker, useComponentProfiler, useNavigationProfiler, trackComponentRender, trackNavigationTransition, trackHeavyTask, measureAsync, getHermesMemoryStats, registerComponentProfile, subscribeRenderProfiles, getRenderProfiles, logPerformanceEvent, clearPerformanceEvents, subscribePerformanceEvents, getPerformanceEvents, getInitialRenderProfiles, getInitialPerformanceEvents, generateFixSnippet, setPerformanceModuleEnabled, getPerformanceModuleEnabled, setMaxPerformanceEventsLimit, getMaxPerformanceEventsLimit, prunePerformanceEvents, } from './customHooks/performanceTracker';
|
|
6
2
|
export { PerformanceSubTab, } from './types';
|
package/dist/esm/redux.d.ts
CHANGED
|
@@ -1,5 +1 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Sub-module entry point: react-native-inapp-inspector/redux
|
|
3
|
-
* Clean tree-shaking & isolated Redux middleware and state inspector.
|
|
4
|
-
*/
|
|
5
1
|
export { connectReduxStore, inspectorReduxMiddleware, getReduxState, subscribeReduxState, getActionHistory, clearActionHistory, getLastActionForReducer, clearLastActionForReducer, setReduxAutoRefresh, getReduxAutoRefresh, isReduxConnected, setReduxModuleEnabled, getReduxModuleEnabled, setMaxReduxHistoryLimit, getMaxReduxHistoryLimit, pruneReduxHistory, type ReduxHistoryEntry, } from './customHooks/reduxLogger';
|
package/dist/esm/redux.js
CHANGED
|
@@ -1,5 +1 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Sub-module entry point: react-native-inapp-inspector/redux
|
|
3
|
-
* Clean tree-shaking & isolated Redux middleware and state inspector.
|
|
4
|
-
*/
|
|
5
1
|
export { connectReduxStore, inspectorReduxMiddleware, getReduxState, subscribeReduxState, getActionHistory, clearActionHistory, getLastActionForReducer, clearLastActionForReducer, setReduxAutoRefresh, getReduxAutoRefresh, isReduxConnected, setReduxModuleEnabled, getReduxModuleEnabled, setMaxReduxHistoryLimit, getMaxReduxHistoryLimit, pruneReduxHistory, } from './customHooks/reduxLogger';
|
package/dist/esm/storage.d.ts
CHANGED
|
@@ -1,5 +1 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Sub-module entry point: react-native-inapp-inspector/storage
|
|
3
|
-
* Universal AsyncStorage and MMKV live inspector with full CRUD operations.
|
|
4
|
-
*/
|
|
5
1
|
export { connectAsyncStorage, connectMMKV, isAsyncStorageConnected, isMMKVConnected, getRegisteredMMKVInstanceIds, fetchStorageEntries, setStorageEntry, removeStorageEntry, clearStorageDriver, subscribeToStorageChanges, type StorageEntry, type StorageDriver, } from './customHooks/storageInspector';
|
package/dist/esm/storage.js
CHANGED
|
@@ -1,5 +1 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Sub-module entry point: react-native-inapp-inspector/storage
|
|
3
|
-
* Universal AsyncStorage and MMKV live inspector with full CRUD operations.
|
|
4
|
-
*/
|
|
5
1
|
export { connectAsyncStorage, connectMMKV, isAsyncStorageConnected, isMMKVConnected, getRegisteredMMKVInstanceIds, fetchStorageEntries, setStorageEntry, removeStorageEntry, clearStorageDriver, subscribeToStorageChanges, } from './customHooks/storageInspector';
|
|
@@ -344,8 +344,5 @@ export declare const getThemeColors: (isDark: boolean) => {
|
|
|
344
344
|
};
|
|
345
345
|
export declare const AppColors: typeof LightColors;
|
|
346
346
|
export declare const updateAppColorsTheme: (isDark: boolean) => void;
|
|
347
|
-
/**
|
|
348
|
-
* Configure or override specific color tokens used throughout the inspector.
|
|
349
|
-
*/
|
|
350
347
|
export declare const setAppColors: (customColors: Partial<typeof LightColors>) => void;
|
|
351
348
|
export default AppColors;
|
|
@@ -1,37 +1,34 @@
|
|
|
1
1
|
const LightColors = {
|
|
2
|
-
// ─── Core (Thai Airways Royal Palette) ───
|
|
3
2
|
primaryLight: '#FFFFFF',
|
|
4
|
-
purple: '#5C2D91',
|
|
5
|
-
purpleShade50: '#F8F4FC',
|
|
6
|
-
offerPurple: '#9B2677',
|
|
3
|
+
purple: '#5C2D91',
|
|
4
|
+
purpleShade50: '#F8F4FC',
|
|
5
|
+
offerPurple: '#9B2677',
|
|
7
6
|
grayBorderSecondary: '#E2DFEB',
|
|
8
|
-
grayBackground: '#F8F7FB',
|
|
7
|
+
grayBackground: '#F8F7FB',
|
|
9
8
|
grayText: '#625D73',
|
|
10
9
|
grayTextWeak: '#8F8A9E',
|
|
11
10
|
greenColor: '#10B981',
|
|
12
11
|
graySurface: '#E2DFEB',
|
|
13
12
|
skyBlue: '#2563EB',
|
|
14
|
-
primaryBlack: '#211B30',
|
|
13
|
+
primaryBlack: '#211B30',
|
|
15
14
|
grayTextStrong: '#211B30',
|
|
16
15
|
dividerColor: '#EBE7F2',
|
|
17
|
-
warningIconGold: '#C5A059',
|
|
16
|
+
warningIconGold: '#C5A059',
|
|
18
17
|
shadowColorString: '#211B30',
|
|
19
18
|
errorColor: '#E11D48',
|
|
20
|
-
lightOrange: '#E5C158',
|
|
21
|
-
darkOrange: '#B89758',
|
|
19
|
+
lightOrange: '#E5C158',
|
|
20
|
+
darkOrange: '#B89758',
|
|
22
21
|
successGreen: '#10B981',
|
|
23
|
-
purpleShade700: '#481E78',
|
|
22
|
+
purpleShade700: '#481E78',
|
|
24
23
|
greenStatus: '#D1FAE5',
|
|
25
24
|
greenBaggageText: '#059669',
|
|
26
|
-
paleYellow: '#F7E9C4',
|
|
27
|
-
// ─── Brand / UI ───
|
|
25
|
+
paleYellow: '#F7E9C4',
|
|
28
26
|
white: '#FFFFFF',
|
|
29
27
|
black: '#000000',
|
|
30
|
-
brandPurple: '#4B1B7D',
|
|
28
|
+
brandPurple: '#4B1B7D',
|
|
31
29
|
liveGreen: '#10B981',
|
|
32
30
|
firebaseOrange: '#D97706',
|
|
33
31
|
greenA400: '#00E676',
|
|
34
|
-
// ─── Code / Slate ───
|
|
35
32
|
slate900: '#171226',
|
|
36
33
|
slate700: '#332C4A',
|
|
37
34
|
slate600: '#4D446B',
|
|
@@ -44,7 +41,6 @@ const LightColors = {
|
|
|
44
41
|
gray300: '#D5D0E0',
|
|
45
42
|
highlightYellow: '#FDE047',
|
|
46
43
|
yellowHighlight: '#FFE44D',
|
|
47
|
-
// ─── Status / Syntax ───
|
|
48
44
|
teal600: '#0D9488',
|
|
49
45
|
cyan600: '#0891B2',
|
|
50
46
|
sky600: '#0284C7',
|
|
@@ -78,7 +74,6 @@ const LightColors = {
|
|
|
78
74
|
googleRed: '#E53935',
|
|
79
75
|
googlePurple: '#5C2D91',
|
|
80
76
|
googleTeal: '#00897B',
|
|
81
|
-
// ─── NPM / Package / Tailwind Spectrum Helpers ───
|
|
82
77
|
npmRed: '#CB3837',
|
|
83
78
|
npmRedTint: '#CB383714',
|
|
84
79
|
npmRedBorder: '#CB383733',
|
|
@@ -104,7 +99,6 @@ const LightColors = {
|
|
|
104
99
|
yellow500: '#EAB308',
|
|
105
100
|
slate800: '#1E293B',
|
|
106
101
|
slate850: '#0F172A',
|
|
107
|
-
// ─── Bundle / Extended Spectrum ───
|
|
108
102
|
reanimatedNavy: '#001A72',
|
|
109
103
|
expoViolet: '#5A29E4',
|
|
110
104
|
hermesPurple: '#5B44E0',
|
|
@@ -138,7 +132,6 @@ const LightColors = {
|
|
|
138
132
|
gray200: '#E5E7EB',
|
|
139
133
|
gray500: '#6B7280',
|
|
140
134
|
gray600: '#4B5563',
|
|
141
|
-
// ─── Tint Backgrounds / Borders (Theme-Aware) ───
|
|
142
135
|
errorCardBg: '#FFF1F3',
|
|
143
136
|
warnCardBg: '#FDFBF4',
|
|
144
137
|
blueTintBg: '#EFF6FF',
|
|
@@ -161,7 +154,6 @@ const LightColors = {
|
|
|
161
154
|
greyBorder: '#E3DFEC',
|
|
162
155
|
paperBg: '#FBF9FC',
|
|
163
156
|
contentBg: '#F8F7FB',
|
|
164
|
-
// ─── Toast / Glass / Chip Tokens ───
|
|
165
157
|
toastBg: '#0F172AEE',
|
|
166
158
|
toastBorder: '#33415588',
|
|
167
159
|
mintGreenBg: '#ECFDF5',
|
|
@@ -176,7 +168,6 @@ const LightColors = {
|
|
|
176
168
|
skySoftBg: '#E0F2FE',
|
|
177
169
|
skySoftBorder: '#BAE6FD',
|
|
178
170
|
skySoftText: '#0284C7',
|
|
179
|
-
// ─── Domain Colors (Thai Airways Themed) ───
|
|
180
171
|
domainColors: [
|
|
181
172
|
'#5C2D91',
|
|
182
173
|
'#9B2677',
|
|
@@ -191,12 +182,12 @@ const LightColors = {
|
|
|
191
182
|
],
|
|
192
183
|
};
|
|
193
184
|
const DarkColors = {
|
|
194
|
-
primaryLight: '#1C1628',
|
|
195
|
-
purple: '#B68FE8',
|
|
185
|
+
primaryLight: '#1C1628',
|
|
186
|
+
purple: '#B68FE8',
|
|
196
187
|
purpleShade50: '#2A1C3E',
|
|
197
188
|
offerPurple: '#F472B6',
|
|
198
189
|
grayBorderSecondary: '#362C4E',
|
|
199
|
-
grayBackground: '#130F1F',
|
|
190
|
+
grayBackground: '#130F1F',
|
|
200
191
|
grayText: '#A197B8',
|
|
201
192
|
grayTextWeak: '#756C8C',
|
|
202
193
|
greenColor: '#34D399',
|
|
@@ -205,7 +196,7 @@ const DarkColors = {
|
|
|
205
196
|
primaryBlack: '#F7F5FC',
|
|
206
197
|
grayTextStrong: '#F7F5FC',
|
|
207
198
|
dividerColor: '#2B2240',
|
|
208
|
-
warningIconGold: '#E5C158',
|
|
199
|
+
warningIconGold: '#E5C158',
|
|
209
200
|
shadowColorString: '#000000',
|
|
210
201
|
errorColor: '#F87171',
|
|
211
202
|
lightOrange: '#FDE68A',
|
|
@@ -252,7 +243,6 @@ const DarkColors = {
|
|
|
252
243
|
amber700: '#C5A059',
|
|
253
244
|
amber800: '#B89758',
|
|
254
245
|
green500: '#22C55E',
|
|
255
|
-
// ─── Toast / Glass / Chip Tokens (Dark) ───
|
|
256
246
|
toastBg: '#1E293BEE',
|
|
257
247
|
toastBorder: '#47556988',
|
|
258
248
|
mintGreenBg: '#064E3B66',
|
|
@@ -281,7 +271,6 @@ const DarkColors = {
|
|
|
281
271
|
googleRed: '#F87171',
|
|
282
272
|
googlePurple: '#C084FC',
|
|
283
273
|
googleTeal: '#2DD4BF',
|
|
284
|
-
// ─── NPM / Package / Tailwind Spectrum Helpers ───
|
|
285
274
|
npmRed: '#CB3837',
|
|
286
275
|
npmRedTint: '#CB383714',
|
|
287
276
|
npmRedBorder: '#CB383733',
|
|
@@ -307,7 +296,6 @@ const DarkColors = {
|
|
|
307
296
|
yellow500: '#EAB308',
|
|
308
297
|
slate800: '#1E293B',
|
|
309
298
|
slate850: '#0F172A',
|
|
310
|
-
// ─── Bundle / Extended Spectrum ───
|
|
311
299
|
reanimatedNavy: '#6B8CFF',
|
|
312
300
|
expoViolet: '#A78BFA',
|
|
313
301
|
hermesPurple: '#9B8AFF',
|
|
@@ -384,9 +372,6 @@ Object.assign(AppColors, LightColors);
|
|
|
384
372
|
export const updateAppColorsTheme = (isDark) => {
|
|
385
373
|
Object.assign(AppColors, getThemeColors(isDark));
|
|
386
374
|
};
|
|
387
|
-
/**
|
|
388
|
-
* Configure or override specific color tokens used throughout the inspector.
|
|
389
|
-
*/
|
|
390
375
|
export const setAppColors = (customColors) => {
|
|
391
376
|
if (!customColors || typeof customColors !== 'object')
|
|
392
377
|
return;
|
|
@@ -10,9 +10,5 @@ export declare const AppFonts: {
|
|
|
10
10
|
interBold: string;
|
|
11
11
|
Sfprotext: string;
|
|
12
12
|
};
|
|
13
|
-
/**
|
|
14
|
-
* Configure or override font families used across all inspector screens.
|
|
15
|
-
* Useful when integrating into apps with custom font setups or system fonts.
|
|
16
|
-
*/
|
|
17
13
|
export declare const setAppFonts: (customFonts: Partial<typeof AppFonts>) => void;
|
|
18
14
|
export default AppFonts;
|
|
@@ -4,10 +4,6 @@ export const AppFonts = {
|
|
|
4
4
|
interBold: 'Inter-Bold',
|
|
5
5
|
Sfprotext: 'Inter-Regular',
|
|
6
6
|
};
|
|
7
|
-
/**
|
|
8
|
-
* Configure or override font families used across all inspector screens.
|
|
9
|
-
* Useful when integrating into apps with custom font setups or system fonts.
|
|
10
|
-
*/
|
|
11
7
|
export const setAppFonts = (customFonts) => {
|
|
12
8
|
if (!customFonts || typeof customFonts !== 'object')
|
|
13
9
|
return;
|
|
@@ -1,13 +1,9 @@
|
|
|
1
1
|
import { StyleSheet } from 'react-native';
|
|
2
2
|
import { AppFonts } from './AppFonts';
|
|
3
3
|
import { AppColors } from './AppColors';
|
|
4
|
-
// Shared styles for the Inspector UI (repeated patterns + page-level layout).
|
|
5
|
-
// Built dynamically so dark-mode colors stay in sync with toggleGlobalTheme()
|
|
6
|
-
// (see rebuildCommonStyles wired into styles/index.ts).
|
|
7
4
|
const commonStyles = {};
|
|
8
5
|
const buildCommonStyles = (colors) => {
|
|
9
6
|
const newStyles = StyleSheet.create({
|
|
10
|
-
// ─── Layout ──────────────────────────────────────────────────────────────
|
|
11
7
|
pageContainer: {
|
|
12
8
|
flex: 1,
|
|
13
9
|
backgroundColor: colors.grayBackground,
|
|
@@ -34,7 +30,6 @@ const buildCommonStyles = (colors) => {
|
|
|
34
30
|
justifyContent: 'space-between',
|
|
35
31
|
gap: 8,
|
|
36
32
|
},
|
|
37
|
-
// ─── Cards / rows ────────────────────────────────────────────────────────
|
|
38
33
|
card: {
|
|
39
34
|
backgroundColor: colors.primaryLight,
|
|
40
35
|
borderRadius: 12,
|
|
@@ -70,7 +65,6 @@ const buildCommonStyles = (colors) => {
|
|
|
70
65
|
gap: 8,
|
|
71
66
|
alignItems: 'flex-start',
|
|
72
67
|
},
|
|
73
|
-
// ─── Search bar ──────────────────────────────────────────────────────────
|
|
74
68
|
searchBar: {
|
|
75
69
|
flexDirection: 'row',
|
|
76
70
|
alignItems: 'center',
|
|
@@ -84,7 +78,6 @@ const buildCommonStyles = (colors) => {
|
|
|
84
78
|
borderColor: colors.dividerColor,
|
|
85
79
|
height: 36,
|
|
86
80
|
},
|
|
87
|
-
// ─── Tabs / pills ────────────────────────────────────────────────────────
|
|
88
81
|
tabBarStrip: {
|
|
89
82
|
backgroundColor: colors.primaryLight,
|
|
90
83
|
borderBottomWidth: 1,
|
|
@@ -134,7 +127,6 @@ const buildCommonStyles = (colors) => {
|
|
|
134
127
|
justifyContent: 'center',
|
|
135
128
|
backgroundColor: colors.grayBackground,
|
|
136
129
|
},
|
|
137
|
-
// ─── Header / address bar ────────────────────────────────────────────────
|
|
138
130
|
addressBar: {
|
|
139
131
|
paddingHorizontal: 12,
|
|
140
132
|
paddingTop: 6,
|
|
@@ -164,7 +156,6 @@ const buildCommonStyles = (colors) => {
|
|
|
164
156
|
borderBottomWidth: 1,
|
|
165
157
|
borderBottomColor: colors.dividerColor,
|
|
166
158
|
},
|
|
167
|
-
// ─── Badges / buttons ────────────────────────────────────────────────────
|
|
168
159
|
badgeActive: {
|
|
169
160
|
flexDirection: 'row',
|
|
170
161
|
alignItems: 'center',
|
|
@@ -185,11 +176,9 @@ const buildCommonStyles = (colors) => {
|
|
|
185
176
|
justifyContent: 'center',
|
|
186
177
|
},
|
|
187
178
|
});
|
|
188
|
-
// Clear old keys and copy new ones (keeps the exported object identity).
|
|
189
179
|
Object.keys(commonStyles).forEach(key => delete commonStyles[key]);
|
|
190
180
|
Object.assign(commonStyles, newStyles);
|
|
191
181
|
};
|
|
192
|
-
// Initial build
|
|
193
182
|
buildCommonStyles(AppColors);
|
|
194
183
|
export const rebuildCommonStyles = (colors) => {
|
|
195
184
|
buildCommonStyles(colors);
|
package/dist/esm/styles/index.js
CHANGED
|
@@ -137,7 +137,6 @@ export const getRawStyles = (colors) => ({
|
|
|
137
137
|
letterSpacing: 0.2,
|
|
138
138
|
},
|
|
139
139
|
listContent: { paddingBottom: Platform.OS === 'ios' ? 44 : 32 },
|
|
140
|
-
// #2 — scroll-to-top button, always shown at the bottom right.
|
|
141
140
|
scrollTopBtn: {
|
|
142
141
|
position: 'absolute',
|
|
143
142
|
bottom: 22,
|
|
@@ -187,7 +186,6 @@ export const getRawStyles = (colors) => ({
|
|
|
187
186
|
borderRadius: 30,
|
|
188
187
|
backgroundColor: `${colors.purple}25`,
|
|
189
188
|
},
|
|
190
|
-
// #4 — circular clipping mask for the FAB shine sweep.
|
|
191
189
|
fabShineClip: {
|
|
192
190
|
position: 'absolute',
|
|
193
191
|
width: 62,
|
|
@@ -195,7 +193,6 @@ export const getRawStyles = (colors) => ({
|
|
|
195
193
|
borderRadius: 31,
|
|
196
194
|
overflow: 'hidden',
|
|
197
195
|
},
|
|
198
|
-
// #4 — diagonal light streak that sweeps across the launcher.
|
|
199
196
|
fabShineStreak: {
|
|
200
197
|
position: 'absolute',
|
|
201
198
|
top: -20,
|
|
@@ -1332,7 +1329,6 @@ export const getRawStyles = (colors) => ({
|
|
|
1332
1329
|
borderTopRightRadius: 20,
|
|
1333
1330
|
overflow: 'hidden',
|
|
1334
1331
|
},
|
|
1335
|
-
// Status chip used in MetaAccordion
|
|
1336
1332
|
statusChip: {
|
|
1337
1333
|
paddingHorizontal: 10,
|
|
1338
1334
|
paddingVertical: 4,
|
|
@@ -1343,8 +1339,6 @@ export const getRawStyles = (colors) => ({
|
|
|
1343
1339
|
fontFamily: AppFonts.interBold,
|
|
1344
1340
|
fontSize: 12,
|
|
1345
1341
|
},
|
|
1346
|
-
// ─── Tab Bar ───────────────────────────────────────────────────────────────
|
|
1347
|
-
// ─── Screen Grouping Headers ───────────────────────────────────────────────
|
|
1348
1342
|
modalBackdrop: {
|
|
1349
1343
|
flex: 1,
|
|
1350
1344
|
backgroundColor: `${colors.black}73`,
|
|
@@ -1509,11 +1503,9 @@ const styles = {};
|
|
|
1509
1503
|
const rebuildStyles = (isDark) => {
|
|
1510
1504
|
const colors = isDark ? getThemeColors(true) : AppColors;
|
|
1511
1505
|
const newStyles = getRawStyles(colors);
|
|
1512
|
-
// Clear old keys and copy new ones
|
|
1513
1506
|
Object.keys(styles).forEach(key => delete styles[key]);
|
|
1514
1507
|
Object.assign(styles, newStyles);
|
|
1515
1508
|
};
|
|
1516
|
-
// Initial build
|
|
1517
1509
|
rebuildStyles(false);
|
|
1518
1510
|
export const toggleGlobalTheme = (isDark) => {
|
|
1519
1511
|
updateAppColorsTheme(isDark);
|
package/dist/esm/types/enums.js
CHANGED
|
@@ -1,6 +1,3 @@
|
|
|
1
|
-
// ─── Enums & Constants ─────────────────────────────────────────────────────────
|
|
2
|
-
// Universal TypeScript Enum Objects and Type Aliases.
|
|
3
|
-
// Allows both enum-style access (e.g. ActiveTab.Apis) and string literals ('apis').
|
|
4
1
|
export const ActiveTab = {
|
|
5
2
|
Apis: 'apis',
|
|
6
3
|
Analytics: 'analytics',
|