react-native-inapp-inspector 2.2.2 → 2.2.4
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/components/AnalyticsDetail.js +5 -1
- package/dist/commonjs/components/AnalyticsEventCard.js +2 -1
- package/dist/commonjs/components/DiffViewer.js +1 -1
- package/dist/commonjs/components/Inspector/BundleTab.js +22 -0
- package/dist/commonjs/components/Inspector/DeviceInfoTab.d.ts +3 -0
- package/dist/commonjs/components/Inspector/DeviceInfoTab.js +835 -0
- package/dist/commonjs/components/Inspector/InspectorHeader.js +12 -14
- package/dist/commonjs/components/Inspector/LogDetail.js +6 -3
- package/dist/commonjs/components/Inspector/MainScreen.js +7 -3
- package/dist/commonjs/components/Inspector/NetworkTab.js +92 -15
- package/dist/commonjs/components/Inspector/PerformanceTab.js +38 -12
- package/dist/commonjs/components/Inspector/SettingsPanel.js +440 -229
- package/dist/commonjs/components/Inspector/StorageTab.d.ts +3 -0
- package/dist/commonjs/components/Inspector/StorageTab.js +892 -0
- package/dist/commonjs/components/Inspector/TabBar.js +14 -0
- package/dist/commonjs/components/Inspector/TelemetryConsentModal.js +11 -2
- package/dist/commonjs/components/Inspector/UpdateAvailableModal.js +4 -1
- package/dist/commonjs/components/NetworkIcons.d.ts +6 -0
- package/dist/commonjs/components/NetworkIcons.js +30 -1
- package/dist/commonjs/constants/version.d.ts +1 -1
- package/dist/commonjs/constants/version.js +1 -1
- package/dist/commonjs/customHooks/bundleAnalyzer.js +44 -22
- package/dist/commonjs/customHooks/storageInspector.d.ts +67 -0
- package/dist/commonjs/customHooks/storageInspector.js +486 -0
- package/dist/commonjs/i18n/locales/en.json +8 -2
- package/dist/commonjs/index.d.ts +1 -0
- package/dist/commonjs/index.js +16 -1
- package/dist/commonjs/storage.d.ts +5 -0
- package/dist/commonjs/storage.js +18 -0
- package/dist/commonjs/types/enums.d.ts +5 -0
- package/dist/commonjs/types/enums.js +5 -0
- package/dist/esm/components/AnalyticsDetail.js +6 -2
- package/dist/esm/components/AnalyticsEventCard.js +2 -1
- package/dist/esm/components/DiffViewer.js +1 -1
- package/dist/esm/components/Inspector/BundleTab.js +22 -0
- package/dist/esm/components/Inspector/DeviceInfoTab.d.ts +3 -0
- package/dist/esm/components/Inspector/DeviceInfoTab.js +796 -0
- package/dist/esm/components/Inspector/InspectorHeader.js +13 -15
- package/dist/esm/components/Inspector/LogDetail.js +7 -4
- package/dist/esm/components/Inspector/MainScreen.js +7 -3
- package/dist/esm/components/Inspector/NetworkTab.js +93 -16
- package/dist/esm/components/Inspector/PerformanceTab.js +39 -13
- package/dist/esm/components/Inspector/SettingsPanel.js +441 -230
- package/dist/esm/components/Inspector/StorageTab.d.ts +3 -0
- package/dist/esm/components/Inspector/StorageTab.js +853 -0
- package/dist/esm/components/Inspector/TabBar.js +15 -1
- package/dist/esm/components/Inspector/TelemetryConsentModal.js +11 -2
- package/dist/esm/components/Inspector/UpdateAvailableModal.js +4 -1
- package/dist/esm/components/NetworkIcons.d.ts +6 -0
- package/dist/esm/components/NetworkIcons.js +23 -0
- package/dist/esm/constants/version.d.ts +1 -1
- package/dist/esm/constants/version.js +1 -1
- package/dist/esm/customHooks/bundleAnalyzer.js +44 -22
- package/dist/esm/customHooks/storageInspector.d.ts +67 -0
- package/dist/esm/customHooks/storageInspector.js +469 -0
- package/dist/esm/i18n/locales/en.json +8 -2
- package/dist/esm/index.d.ts +1 -0
- package/dist/esm/index.js +5 -0
- package/dist/esm/storage.d.ts +5 -0
- package/dist/esm/storage.js +5 -0
- package/dist/esm/types/enums.d.ts +5 -0
- package/dist/esm/types/enums.js +5 -0
- package/package.json +9 -1
- package/src/analytics.ts +35 -0
- package/src/bundle.ts +25 -0
- package/src/components/AnalyticsDetail.tsx +870 -0
- package/src/components/AnalyticsEventCard.tsx +442 -0
- package/src/components/AnalyticsGraph.tsx +583 -0
- package/src/components/AnimatedEntrance.tsx +64 -0
- package/src/components/AppHeaderLogo.tsx +109 -0
- package/src/components/BrandCircleIcon.tsx +144 -0
- package/src/components/BrandSquareIcon.tsx +144 -0
- package/src/components/CodeSnippet.tsx +725 -0
- package/src/components/ConsoleLogCard.tsx +628 -0
- package/src/components/CopyButton.tsx +87 -0
- package/src/components/DiffViewer.tsx +82 -0
- package/src/components/DomainHeader.tsx +237 -0
- package/src/components/EmptyState.tsx +73 -0
- package/src/components/EndOfListFooter.tsx +100 -0
- package/src/components/ErrorBoundary.tsx +688 -0
- package/src/components/HeadersSection.tsx +192 -0
- package/src/components/HighlightText.tsx +100 -0
- package/src/components/Inspector/AnalyticsFilterModal.tsx +1250 -0
- package/src/components/Inspector/AnalyticsTab.tsx +1336 -0
- package/src/components/Inspector/BundleTab.tsx +4760 -0
- package/src/components/Inspector/ConsoleTab.tsx +702 -0
- package/src/components/Inspector/CrashDetail.tsx +941 -0
- package/src/components/Inspector/CrashFilterModal.tsx +721 -0
- package/src/components/Inspector/CrashTab.tsx +871 -0
- package/src/components/Inspector/DeviceInfoTab.tsx +1204 -0
- package/src/components/Inspector/FabLauncher.tsx +80 -0
- package/src/components/Inspector/InspectorContext.tsx +28 -0
- package/src/components/Inspector/InspectorHeader.tsx +972 -0
- package/src/components/Inspector/LogDetail.tsx +1431 -0
- package/src/components/Inspector/MainScreen.tsx +262 -0
- package/src/components/Inspector/NavigationTracker.tsx +13 -0
- package/src/components/Inspector/NetworkDetail.tsx +794 -0
- package/src/components/Inspector/NetworkTab.tsx +1183 -0
- package/src/components/Inspector/NpmUpdateToast.tsx +392 -0
- package/src/components/Inspector/PerformanceTab.tsx +1928 -0
- package/src/components/Inspector/ReduxDetail.tsx +1651 -0
- package/src/components/Inspector/ReduxTab.tsx +954 -0
- package/src/components/Inspector/SettingsPanel.tsx +3447 -0
- package/src/components/Inspector/StorageTab.tsx +1048 -0
- package/src/components/Inspector/TabBar.tsx +207 -0
- package/src/components/Inspector/TelemetryConsentModal.tsx +416 -0
- package/src/components/Inspector/UpdateAvailableModal.tsx +557 -0
- package/src/components/JsonViewer.tsx +486 -0
- package/src/components/LogCard.tsx +491 -0
- package/src/components/LogSyntaxHighlighter.tsx +178 -0
- package/src/components/MetaAccordion.tsx +340 -0
- package/src/components/MiniBarChart.tsx +42 -0
- package/src/components/MiniLineChart.tsx +33 -0
- package/src/components/NetworkIcons.tsx +2221 -0
- package/src/components/SectionHeader.tsx +113 -0
- package/src/components/SegmentedTabs.tsx +83 -0
- package/src/components/Slider.tsx +300 -0
- package/src/components/SourcePageCard.tsx +148 -0
- package/src/components/Toast.tsx +131 -0
- package/src/components/TouchableScale.tsx +91 -0
- package/src/components/TreeNode.tsx +186 -0
- package/src/console.ts +24 -0
- package/src/constants/index.ts +38 -0
- package/src/constants/version.ts +3 -0
- package/src/crash.ts +32 -0
- package/src/customHooks/analyticsLogger.ts +336 -0
- package/src/customHooks/bundleAnalyzer.ts +1256 -0
- package/src/customHooks/consoleLogger.ts +497 -0
- package/src/customHooks/crashHandler.ts +944 -0
- package/src/customHooks/logFilters.ts +32 -0
- package/src/customHooks/networkLogger.ts +419 -0
- package/src/customHooks/performanceTracker.ts +1014 -0
- package/src/customHooks/reduxLogger.ts +406 -0
- package/src/customHooks/storageInspector.ts +509 -0
- package/src/customHooks/useAccordion.tsx +60 -0
- package/src/decorators/index.ts +184 -0
- package/src/helpers/gaAnalyticsRegistry.ts +204 -0
- package/src/helpers/index.ts +860 -0
- package/src/helpers/memoryManager.ts +138 -0
- package/src/helpers/searchQueryParser.ts +283 -0
- package/src/helpers/settingsStore.ts +171 -0
- package/src/helpers/telemetry.ts +505 -0
- package/src/helpers/toast.ts +17 -0
- package/src/i18n/index.ts +69 -0
- package/src/i18n/locales/en.json +1058 -0
- package/src/index.tsx +2356 -0
- package/src/native/NativeInspector.ts +397 -0
- package/src/native/NativeNetworkInspector.ts +24 -0
- package/src/network.ts +22 -0
- package/src/performance.ts +38 -0
- package/src/redux.ts +23 -0
- package/src/storage.ts +18 -0
- package/src/styles/AppColors.ts +408 -0
- package/src/styles/AppFonts.ts +8 -0
- package/src/styles/common.ts +209 -0
- package/src/styles/index.ts +1570 -0
- package/src/types/enums.ts +199 -0
- package/src/types/index.ts +34 -0
- package/src/types/interfaces.ts +515 -0
|
@@ -60,6 +60,7 @@ const NetworkIcons_1 = require("../NetworkIcons");
|
|
|
60
60
|
const constants_1 = require("../../constants");
|
|
61
61
|
const helpers_1 = require("../../helpers");
|
|
62
62
|
const toast_1 = require("../../helpers/toast");
|
|
63
|
+
const memoryManager_1 = require("../../helpers/memoryManager");
|
|
63
64
|
const SettingsPanel = () => {
|
|
64
65
|
const { t } = (0, i18n_1.useTranslation)();
|
|
65
66
|
const { settingsPage, setSettingsPage, settingsActiveSubTab, setSettingsActiveSubTab, tabVisibility, toggleTabVisibility, defaultTab, setDefaultTab, isDark, setIsDark, modalHeightPercent, setModalHeightPercent, modalAnimationType, setModalAnimationType, showDuplicateLogs, setShowDuplicateLogs, showUpdateToast, setShowUpdateToast, showConsoleLevels, setShowConsoleLevels, resetToDefaults, storage, logs, consoleLogs, analyticsEvents, reduxState, maxNetworkLogs, setMaxNetworkLogs, maxConsoleLogs, setMaxConsoleLogs, maxAnalyticsEventsLimit, setMaxAnalyticsEventsLimit, isAutoRamLimitEnabled, setIsAutoRamLimitEnabled, deviceFreeRamMb, reduxAutoRefresh, setReduxAutoRefreshState, reduxExpandDepth, setReduxExpandDepth, switchActiveTab, setSelected, setSelectedEvent, setReduxState, crashRecords, maxCrashLogs, setMaxCrashLogs, updateAvailable, latestNpmVersion, } = (0, InspectorContext_1.useInspector)();
|
|
@@ -136,6 +137,20 @@ const SettingsPanel = () => {
|
|
|
136
137
|
icon: 'redux',
|
|
137
138
|
desc: 'Store state diffing, action history & reducer timeline',
|
|
138
139
|
},
|
|
140
|
+
{
|
|
141
|
+
key: 'device',
|
|
142
|
+
label: 'Device Info',
|
|
143
|
+
category: 'diagnostic',
|
|
144
|
+
icon: 'device',
|
|
145
|
+
desc: 'Hardware specs, IP address, screen metrics, UDID & runtime stats',
|
|
146
|
+
},
|
|
147
|
+
{
|
|
148
|
+
key: 'storage',
|
|
149
|
+
label: 'Storage Inspector',
|
|
150
|
+
category: 'telemetry',
|
|
151
|
+
icon: 'storage',
|
|
152
|
+
desc: 'AsyncStorage & MMKV key-value store viewer with full CRUD support',
|
|
153
|
+
},
|
|
139
154
|
];
|
|
140
155
|
// Staged selection state for checkboxes before clicking "Save Changes"
|
|
141
156
|
const [stagedTabVisibility, setStagedTabVisibility] = (0, react_1.useState)(() => ({
|
|
@@ -146,6 +161,8 @@ const SettingsPanel = () => {
|
|
|
146
161
|
bundle: Boolean(tabVisibility?.bundle),
|
|
147
162
|
performance: Boolean(tabVisibility?.performance),
|
|
148
163
|
crash: Boolean(tabVisibility?.crash),
|
|
164
|
+
device: Boolean(tabVisibility?.device ?? true),
|
|
165
|
+
storage: Boolean(tabVisibility?.storage ?? true),
|
|
149
166
|
}));
|
|
150
167
|
// Synchronize staged state with tabVisibility when tabVisibility updates
|
|
151
168
|
(0, react_1.useEffect)(() => {
|
|
@@ -157,6 +174,8 @@ const SettingsPanel = () => {
|
|
|
157
174
|
bundle: Boolean(tabVisibility?.bundle),
|
|
158
175
|
performance: Boolean(tabVisibility?.performance),
|
|
159
176
|
crash: Boolean(tabVisibility?.crash),
|
|
177
|
+
device: Boolean(tabVisibility?.device ?? true),
|
|
178
|
+
storage: Boolean(tabVisibility?.storage ?? true),
|
|
160
179
|
});
|
|
161
180
|
}, [tabVisibility]);
|
|
162
181
|
const hasUnsavedChanges = (0, react_1.useMemo)(() => {
|
|
@@ -364,7 +383,7 @@ const SettingsPanel = () => {
|
|
|
364
383
|
flexDirection: 'row',
|
|
365
384
|
alignItems: 'center',
|
|
366
385
|
justifyContent: 'center',
|
|
367
|
-
gap:
|
|
386
|
+
gap: 5,
|
|
368
387
|
borderRadius: 9,
|
|
369
388
|
backgroundColor: settingsActiveSubTab === 'ui'
|
|
370
389
|
? AppColors_1.AppColors.purple
|
|
@@ -373,9 +392,9 @@ const SettingsPanel = () => {
|
|
|
373
392
|
<NetworkIcons_1.ScreenIcon color={settingsActiveSubTab === 'ui'
|
|
374
393
|
? AppColors_1.AppColors.white
|
|
375
394
|
: AppColors_1.AppColors.grayText} size={13}/>
|
|
376
|
-
<react_native_1.Text style={{
|
|
395
|
+
<react_native_1.Text numberOfLines={1} style={{
|
|
377
396
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
378
|
-
fontSize: 12
|
|
397
|
+
fontSize: 12,
|
|
379
398
|
lineHeight: 16,
|
|
380
399
|
color: settingsActiveSubTab === 'ui'
|
|
381
400
|
? AppColors_1.AppColors.white
|
|
@@ -384,9 +403,39 @@ const SettingsPanel = () => {
|
|
|
384
403
|
{t('settings.uiPreferences')}
|
|
385
404
|
</react_native_1.Text>
|
|
386
405
|
</TouchableScale_1.default>
|
|
406
|
+
|
|
407
|
+
<TouchableScale_1.default accessible={true} accessibilityRole="tab" accessibilityLabel={t('settings.ramLimits')} accessibilityState={{ selected: settingsActiveSubTab === 'limits' }} onPress={() => {
|
|
408
|
+
(0, InspectorContext_1.animateNextLayout)();
|
|
409
|
+
setSettingsActiveSubTab('limits');
|
|
410
|
+
}} style={{
|
|
411
|
+
flex: 1,
|
|
412
|
+
paddingVertical: 9,
|
|
413
|
+
flexDirection: 'row',
|
|
414
|
+
alignItems: 'center',
|
|
415
|
+
justifyContent: 'center',
|
|
416
|
+
gap: 5,
|
|
417
|
+
borderRadius: 9,
|
|
418
|
+
backgroundColor: settingsActiveSubTab === 'limits'
|
|
419
|
+
? AppColors_1.AppColors.purple
|
|
420
|
+
: 'transparent',
|
|
421
|
+
}}>
|
|
422
|
+
<NetworkIcons_1.BrainIcon color={settingsActiveSubTab === 'limits'
|
|
423
|
+
? AppColors_1.AppColors.white
|
|
424
|
+
: AppColors_1.AppColors.grayText} size={13}/>
|
|
425
|
+
<react_native_1.Text numberOfLines={1} style={{
|
|
426
|
+
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
427
|
+
fontSize: 12,
|
|
428
|
+
lineHeight: 16,
|
|
429
|
+
color: settingsActiveSubTab === 'limits'
|
|
430
|
+
? AppColors_1.AppColors.white
|
|
431
|
+
: AppColors_1.AppColors.grayText,
|
|
432
|
+
}}>
|
|
433
|
+
{t('settings.ramLimits')}
|
|
434
|
+
</react_native_1.Text>
|
|
435
|
+
</TouchableScale_1.default>
|
|
387
436
|
</react_native_1.View>
|
|
388
437
|
|
|
389
|
-
{settingsActiveSubTab === 'module'
|
|
438
|
+
{settingsActiveSubTab === 'module' && (<react_native_1.View style={{ gap: 12 }}>
|
|
390
439
|
{/* Individual Module Cards with Left Checkboxes */}
|
|
391
440
|
<react_native_1.View style={{ gap: 10 }}>
|
|
392
441
|
{allModules.map(moduleItem => {
|
|
@@ -524,6 +573,12 @@ const SettingsPanel = () => {
|
|
|
524
573
|
{moduleItem.icon === 'redux' && (<NetworkIcons_1.ReduxIcon color={isChecked
|
|
525
574
|
? AppColors_1.AppColors.purple
|
|
526
575
|
: AppColors_1.AppColors.grayTextWeak} size={16}/>)}
|
|
576
|
+
{moduleItem.icon === 'device' && (<NetworkIcons_1.SmartphoneIcon color={isChecked
|
|
577
|
+
? AppColors_1.AppColors.purple
|
|
578
|
+
: AppColors_1.AppColors.grayTextWeak} size={16}/>)}
|
|
579
|
+
{moduleItem.icon === 'storage' && (<NetworkIcons_1.DatabaseIcon color={isChecked
|
|
580
|
+
? AppColors_1.AppColors.purple
|
|
581
|
+
: AppColors_1.AppColors.grayTextWeak} size={16}/>)}
|
|
527
582
|
</react_native_1.View>
|
|
528
583
|
|
|
529
584
|
{/* Titles & Status Pill */}
|
|
@@ -726,231 +781,9 @@ const SettingsPanel = () => {
|
|
|
726
781
|
</react_native_1.View>);
|
|
727
782
|
})}
|
|
728
783
|
</react_native_1.View>
|
|
784
|
+
</react_native_1.View>)}
|
|
729
785
|
|
|
730
|
-
|
|
731
|
-
<react_native_1.View style={{
|
|
732
|
-
backgroundColor: AppColors_1.AppColors.primaryLight,
|
|
733
|
-
borderRadius: 14,
|
|
734
|
-
borderWidth: 1,
|
|
735
|
-
borderColor: AppColors_1.AppColors.grayBorderSecondary,
|
|
736
|
-
overflow: 'hidden',
|
|
737
|
-
padding: 14,
|
|
738
|
-
gap: 12,
|
|
739
|
-
}}>
|
|
740
|
-
<react_native_1.Text style={{
|
|
741
|
-
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
742
|
-
fontSize: 11,
|
|
743
|
-
lineHeight: 14,
|
|
744
|
-
color: AppColors_1.AppColors.grayTextWeak,
|
|
745
|
-
letterSpacing: 0.8,
|
|
746
|
-
}}>
|
|
747
|
-
RAM-Based Auto Limits
|
|
748
|
-
</react_native_1.Text>
|
|
749
|
-
|
|
750
|
-
{/* Auto RAM Limit Toggle */}
|
|
751
|
-
<react_native_1.View style={{
|
|
752
|
-
flexDirection: 'row',
|
|
753
|
-
alignItems: 'center',
|
|
754
|
-
justifyContent: 'space-between',
|
|
755
|
-
}}>
|
|
756
|
-
<react_native_1.View style={{
|
|
757
|
-
flexDirection: 'row',
|
|
758
|
-
alignItems: 'center',
|
|
759
|
-
gap: 10,
|
|
760
|
-
flex: 1,
|
|
761
|
-
}}>
|
|
762
|
-
<react_native_1.View style={{
|
|
763
|
-
width: 32,
|
|
764
|
-
height: 32,
|
|
765
|
-
borderRadius: 8,
|
|
766
|
-
backgroundColor: AppColors_1.AppColors.purpleShade50,
|
|
767
|
-
alignItems: 'center',
|
|
768
|
-
justifyContent: 'center',
|
|
769
|
-
}}>
|
|
770
|
-
<NetworkIcons_1.PerformanceIcon color={AppColors_1.AppColors.purple} size={15}/>
|
|
771
|
-
</react_native_1.View>
|
|
772
|
-
<react_native_1.View style={{ flex: 1 }}>
|
|
773
|
-
<react_native_1.Text style={{
|
|
774
|
-
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
775
|
-
fontSize: 13.5,
|
|
776
|
-
lineHeight: 18,
|
|
777
|
-
color: AppColors_1.AppColors.primaryBlack,
|
|
778
|
-
}}>
|
|
779
|
-
Auto-Calculate Limits from Device RAM
|
|
780
|
-
</react_native_1.Text>
|
|
781
|
-
<react_native_1.Text style={{
|
|
782
|
-
fontFamily: AppFonts_1.AppFonts.interRegular,
|
|
783
|
-
fontSize: 11,
|
|
784
|
-
lineHeight: 15,
|
|
785
|
-
color: AppColors_1.AppColors.grayText,
|
|
786
|
-
marginTop: 1,
|
|
787
|
-
}}>
|
|
788
|
-
Automatically set API, Logs, Analytics & Crash limits
|
|
789
|
-
based on available memory
|
|
790
|
-
</react_native_1.Text>
|
|
791
|
-
</react_native_1.View>
|
|
792
|
-
</react_native_1.View>
|
|
793
|
-
|
|
794
|
-
<TouchableScale_1.default accessible={true} accessibilityRole="switch" accessibilityLabel="Toggle auto RAM limit calculation" accessibilityState={{ checked: isAutoRamLimitEnabled }} onPress={() => setIsAutoRamLimitEnabled(prev => !prev)} style={{
|
|
795
|
-
width: 42,
|
|
796
|
-
height: 24,
|
|
797
|
-
borderRadius: 12,
|
|
798
|
-
backgroundColor: isAutoRamLimitEnabled
|
|
799
|
-
? AppColors_1.AppColors.purple
|
|
800
|
-
: AppColors_1.AppColors.grayBorderSecondary,
|
|
801
|
-
padding: 2,
|
|
802
|
-
justifyContent: 'center',
|
|
803
|
-
alignItems: isAutoRamLimitEnabled
|
|
804
|
-
? 'flex-end'
|
|
805
|
-
: 'flex-start',
|
|
806
|
-
}}>
|
|
807
|
-
<react_native_1.View style={{
|
|
808
|
-
width: 20,
|
|
809
|
-
height: 20,
|
|
810
|
-
borderRadius: 10,
|
|
811
|
-
backgroundColor: AppColors_1.AppColors.white,
|
|
812
|
-
shadowColor: AppColors_1.AppColors.black,
|
|
813
|
-
shadowOpacity: 0.18,
|
|
814
|
-
shadowRadius: 2,
|
|
815
|
-
shadowOffset: { width: 0, height: 1 },
|
|
816
|
-
}}/>
|
|
817
|
-
</TouchableScale_1.default>
|
|
818
|
-
</react_native_1.View>
|
|
819
|
-
|
|
820
|
-
<react_native_1.View style={{ height: 1, backgroundColor: AppColors_1.AppColors.dividerColor }}/>
|
|
821
|
-
|
|
822
|
-
{/* Device Free RAM Display */}
|
|
823
|
-
<react_native_1.View style={{ flexDirection: 'row', alignItems: 'center', gap: 10 }}>
|
|
824
|
-
<react_native_1.View style={{
|
|
825
|
-
width: 32,
|
|
826
|
-
height: 32,
|
|
827
|
-
borderRadius: 8,
|
|
828
|
-
backgroundColor: isAutoRamLimitEnabled
|
|
829
|
-
? `${AppColors_1.AppColors.purple}14`
|
|
830
|
-
: AppColors_1.AppColors.grayBackground,
|
|
831
|
-
alignItems: 'center',
|
|
832
|
-
justifyContent: 'center',
|
|
833
|
-
}}>
|
|
834
|
-
<NetworkIcons_1.SignalIcon color={isAutoRamLimitEnabled
|
|
835
|
-
? AppColors_1.AppColors.purple
|
|
836
|
-
: AppColors_1.AppColors.grayTextWeak} size={15}/>
|
|
837
|
-
</react_native_1.View>
|
|
838
|
-
<react_native_1.View style={{ flex: 1 }}>
|
|
839
|
-
<react_native_1.Text style={{
|
|
840
|
-
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
841
|
-
fontSize: 13.5,
|
|
842
|
-
lineHeight: 18,
|
|
843
|
-
color: isAutoRamLimitEnabled
|
|
844
|
-
? AppColors_1.AppColors.primaryBlack
|
|
845
|
-
: AppColors_1.AppColors.grayText,
|
|
846
|
-
}}>
|
|
847
|
-
Detected Free RAM
|
|
848
|
-
</react_native_1.Text>
|
|
849
|
-
<react_native_1.Text style={{
|
|
850
|
-
fontFamily: AppFonts_1.AppFonts.interRegular,
|
|
851
|
-
fontSize: 11,
|
|
852
|
-
lineHeight: 15,
|
|
853
|
-
color: AppColors_1.AppColors.grayText,
|
|
854
|
-
marginTop: 1,
|
|
855
|
-
}}>
|
|
856
|
-
{deviceFreeRamMb} MB available
|
|
857
|
-
</react_native_1.Text>
|
|
858
|
-
</react_native_1.View>
|
|
859
|
-
<react_native_1.View style={{
|
|
860
|
-
paddingHorizontal: 10,
|
|
861
|
-
paddingVertical: 5,
|
|
862
|
-
borderRadius: 8,
|
|
863
|
-
backgroundColor: isAutoRamLimitEnabled
|
|
864
|
-
? `${AppColors_1.AppColors.purple}12`
|
|
865
|
-
: AppColors_1.AppColors.grayBackground,
|
|
866
|
-
borderWidth: 1,
|
|
867
|
-
borderColor: isAutoRamLimitEnabled
|
|
868
|
-
? `${AppColors_1.AppColors.purple}26`
|
|
869
|
-
: AppColors_1.AppColors.dividerColor,
|
|
870
|
-
}}>
|
|
871
|
-
<react_native_1.Text style={{
|
|
872
|
-
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
873
|
-
fontSize: 12,
|
|
874
|
-
lineHeight: 15,
|
|
875
|
-
color: isAutoRamLimitEnabled
|
|
876
|
-
? AppColors_1.AppColors.purple
|
|
877
|
-
: AppColors_1.AppColors.grayText,
|
|
878
|
-
}}>
|
|
879
|
-
{deviceFreeRamMb} MB
|
|
880
|
-
</react_native_1.Text>
|
|
881
|
-
</react_native_1.View>
|
|
882
|
-
</react_native_1.View>
|
|
883
|
-
|
|
884
|
-
{/* Current Auto-Calculated Limits Preview */}
|
|
885
|
-
{isAutoRamLimitEnabled && (<react_native_1.View style={{
|
|
886
|
-
marginTop: 8,
|
|
887
|
-
paddingTop: 8,
|
|
888
|
-
borderTopWidth: 1,
|
|
889
|
-
borderTopColor: AppColors_1.AppColors.dividerColor,
|
|
890
|
-
gap: 6,
|
|
891
|
-
}}>
|
|
892
|
-
<react_native_1.Text style={{
|
|
893
|
-
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
894
|
-
fontSize: 11.5,
|
|
895
|
-
lineHeight: 15,
|
|
896
|
-
color: AppColors_1.AppColors.purple,
|
|
897
|
-
}}>
|
|
898
|
-
Auto Profile: {autoRamProfile.profileName}
|
|
899
|
-
</react_native_1.Text>
|
|
900
|
-
<react_native_1.View style={{ flexDirection: 'row', flexWrap: 'wrap', gap: 8 }}>
|
|
901
|
-
{[
|
|
902
|
-
{
|
|
903
|
-
label: 'APIs',
|
|
904
|
-
value: autoRamProfile.maxNetworkLogs,
|
|
905
|
-
color: AppColors_1.AppColors.blue500,
|
|
906
|
-
},
|
|
907
|
-
{
|
|
908
|
-
label: 'Logs',
|
|
909
|
-
value: autoRamProfile.maxConsoleLogs,
|
|
910
|
-
color: AppColors_1.AppColors.sky500,
|
|
911
|
-
},
|
|
912
|
-
{
|
|
913
|
-
label: 'Analytics',
|
|
914
|
-
value: autoRamProfile.maxAnalyticsEvents,
|
|
915
|
-
color: AppColors_1.AppColors.purple,
|
|
916
|
-
},
|
|
917
|
-
{
|
|
918
|
-
label: 'Crash',
|
|
919
|
-
value: autoRamProfile.maxCrashRecords,
|
|
920
|
-
color: AppColors_1.AppColors.errorColor,
|
|
921
|
-
},
|
|
922
|
-
].map(item => (<react_native_1.View key={item.label} style={{
|
|
923
|
-
flexDirection: 'row',
|
|
924
|
-
alignItems: 'center',
|
|
925
|
-
gap: 4,
|
|
926
|
-
paddingHorizontal: 8,
|
|
927
|
-
paddingVertical: 4,
|
|
928
|
-
borderRadius: 6,
|
|
929
|
-
backgroundColor: `${item.color}14`,
|
|
930
|
-
borderWidth: 1,
|
|
931
|
-
borderColor: `${item.color}33`,
|
|
932
|
-
}}>
|
|
933
|
-
<react_native_1.Text style={{
|
|
934
|
-
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
935
|
-
fontSize: 10.5,
|
|
936
|
-
lineHeight: 14,
|
|
937
|
-
color: item.color,
|
|
938
|
-
}}>
|
|
939
|
-
{item.label}
|
|
940
|
-
</react_native_1.Text>
|
|
941
|
-
<react_native_1.Text style={{
|
|
942
|
-
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
943
|
-
fontSize: 10.5,
|
|
944
|
-
lineHeight: 14,
|
|
945
|
-
color: item.color,
|
|
946
|
-
}}>
|
|
947
|
-
{item.value}
|
|
948
|
-
</react_native_1.Text>
|
|
949
|
-
</react_native_1.View>))}
|
|
950
|
-
</react_native_1.View>
|
|
951
|
-
</react_native_1.View>)}
|
|
952
|
-
</react_native_1.View>
|
|
953
|
-
</react_native_1.View>) : (<react_native_1.View style={{ gap: 14 }}>
|
|
786
|
+
{settingsActiveSubTab === 'ui' && (<react_native_1.View style={{ gap: 14 }}>
|
|
954
787
|
{/* Section 1: Appearance */}
|
|
955
788
|
<react_native_1.View style={{
|
|
956
789
|
backgroundColor: AppColors_1.AppColors.primaryLight,
|
|
@@ -1638,6 +1471,9 @@ const SettingsPanel = () => {
|
|
|
1638
1471
|
v{constants_1.LIB_VERSION}
|
|
1639
1472
|
</react_native_1.Text>
|
|
1640
1473
|
{updateAvailable ? (<react_native_1.View style={{
|
|
1474
|
+
flexDirection: 'row',
|
|
1475
|
+
alignItems: 'center',
|
|
1476
|
+
gap: 3,
|
|
1641
1477
|
backgroundColor: '#F59E0B20',
|
|
1642
1478
|
paddingHorizontal: 6,
|
|
1643
1479
|
paddingVertical: 1.5,
|
|
@@ -1650,8 +1486,9 @@ const SettingsPanel = () => {
|
|
|
1650
1486
|
fontSize: 9.5,
|
|
1651
1487
|
color: '#D97706',
|
|
1652
1488
|
}}>
|
|
1653
|
-
v{latestNpmVersion} Available
|
|
1489
|
+
v{latestNpmVersion} Available
|
|
1654
1490
|
</react_native_1.Text>
|
|
1491
|
+
<NetworkIcons_1.BoltIcon size={9} color="#D97706"/>
|
|
1655
1492
|
</react_native_1.View>) : (<react_native_1.View style={{
|
|
1656
1493
|
backgroundColor: `${AppColors_1.AppColors.emerald500}20`,
|
|
1657
1494
|
paddingHorizontal: 6,
|
|
@@ -1703,6 +1540,380 @@ const SettingsPanel = () => {
|
|
|
1703
1540
|
</react_native_1.View>
|
|
1704
1541
|
</react_native_1.View>
|
|
1705
1542
|
</react_native_1.View>)}
|
|
1543
|
+
|
|
1544
|
+
{settingsActiveSubTab === 'limits' && (<react_native_1.View style={{ gap: 14 }}>
|
|
1545
|
+
{/* Section 1: Device RAM & Auto Profile */}
|
|
1546
|
+
<react_native_1.View style={{
|
|
1547
|
+
backgroundColor: AppColors_1.AppColors.primaryLight,
|
|
1548
|
+
borderRadius: 14,
|
|
1549
|
+
borderWidth: 1,
|
|
1550
|
+
borderColor: AppColors_1.AppColors.grayBorderSecondary,
|
|
1551
|
+
overflow: 'hidden',
|
|
1552
|
+
padding: 14,
|
|
1553
|
+
gap: 12,
|
|
1554
|
+
}}>
|
|
1555
|
+
<react_native_1.Text style={{
|
|
1556
|
+
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
1557
|
+
fontSize: 11,
|
|
1558
|
+
lineHeight: 14,
|
|
1559
|
+
color: AppColors_1.AppColors.grayTextWeak,
|
|
1560
|
+
letterSpacing: 0.8,
|
|
1561
|
+
}}>
|
|
1562
|
+
DEVICE MEMORY & AUTO PROFILES
|
|
1563
|
+
</react_native_1.Text>
|
|
1564
|
+
|
|
1565
|
+
{/* Auto RAM Limit Toggle */}
|
|
1566
|
+
<react_native_1.View style={{
|
|
1567
|
+
flexDirection: 'row',
|
|
1568
|
+
alignItems: 'center',
|
|
1569
|
+
justifyContent: 'space-between',
|
|
1570
|
+
}}>
|
|
1571
|
+
<react_native_1.View style={{
|
|
1572
|
+
flexDirection: 'row',
|
|
1573
|
+
alignItems: 'center',
|
|
1574
|
+
gap: 10,
|
|
1575
|
+
flex: 1,
|
|
1576
|
+
}}>
|
|
1577
|
+
<react_native_1.View style={{
|
|
1578
|
+
width: 32,
|
|
1579
|
+
height: 32,
|
|
1580
|
+
borderRadius: 8,
|
|
1581
|
+
backgroundColor: AppColors_1.AppColors.purpleShade50,
|
|
1582
|
+
alignItems: 'center',
|
|
1583
|
+
justifyContent: 'center',
|
|
1584
|
+
}}>
|
|
1585
|
+
<NetworkIcons_1.BrainIcon color={AppColors_1.AppColors.purple} size={16}/>
|
|
1586
|
+
</react_native_1.View>
|
|
1587
|
+
<react_native_1.View style={{ flex: 1 }}>
|
|
1588
|
+
<react_native_1.Text style={{
|
|
1589
|
+
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
1590
|
+
fontSize: 13.5,
|
|
1591
|
+
lineHeight: 18,
|
|
1592
|
+
color: AppColors_1.AppColors.primaryBlack,
|
|
1593
|
+
}}>
|
|
1594
|
+
Auto-Calculate Limits from RAM
|
|
1595
|
+
</react_native_1.Text>
|
|
1596
|
+
<react_native_1.Text style={{
|
|
1597
|
+
fontFamily: AppFonts_1.AppFonts.interRegular,
|
|
1598
|
+
fontSize: 11,
|
|
1599
|
+
lineHeight: 15,
|
|
1600
|
+
color: AppColors_1.AppColors.grayText,
|
|
1601
|
+
marginTop: 1,
|
|
1602
|
+
}}>
|
|
1603
|
+
Dynamically sets log limits according to available device memory
|
|
1604
|
+
</react_native_1.Text>
|
|
1605
|
+
</react_native_1.View>
|
|
1606
|
+
</react_native_1.View>
|
|
1607
|
+
|
|
1608
|
+
<TouchableScale_1.default accessible={true} accessibilityRole="switch" accessibilityLabel="Toggle auto RAM limit calculation" accessibilityState={{ checked: isAutoRamLimitEnabled }} onPress={() => setIsAutoRamLimitEnabled(prev => !prev)} style={{
|
|
1609
|
+
width: 42,
|
|
1610
|
+
height: 24,
|
|
1611
|
+
borderRadius: 12,
|
|
1612
|
+
backgroundColor: isAutoRamLimitEnabled
|
|
1613
|
+
? AppColors_1.AppColors.purple
|
|
1614
|
+
: AppColors_1.AppColors.grayBorderSecondary,
|
|
1615
|
+
padding: 2,
|
|
1616
|
+
justifyContent: 'center',
|
|
1617
|
+
alignItems: isAutoRamLimitEnabled
|
|
1618
|
+
? 'flex-end'
|
|
1619
|
+
: 'flex-start',
|
|
1620
|
+
}}>
|
|
1621
|
+
<react_native_1.View style={{
|
|
1622
|
+
width: 20,
|
|
1623
|
+
height: 20,
|
|
1624
|
+
borderRadius: 10,
|
|
1625
|
+
backgroundColor: AppColors_1.AppColors.white,
|
|
1626
|
+
shadowColor: AppColors_1.AppColors.black,
|
|
1627
|
+
shadowOpacity: 0.18,
|
|
1628
|
+
shadowRadius: 2,
|
|
1629
|
+
shadowOffset: { width: 0, height: 1 },
|
|
1630
|
+
}}/>
|
|
1631
|
+
</TouchableScale_1.default>
|
|
1632
|
+
</react_native_1.View>
|
|
1633
|
+
|
|
1634
|
+
<react_native_1.View style={{ height: 1, backgroundColor: AppColors_1.AppColors.dividerColor }}/>
|
|
1635
|
+
|
|
1636
|
+
{/* Device Free RAM Display */}
|
|
1637
|
+
<react_native_1.View style={{ flexDirection: 'row', alignItems: 'center', gap: 10 }}>
|
|
1638
|
+
<react_native_1.View style={{
|
|
1639
|
+
width: 32,
|
|
1640
|
+
height: 32,
|
|
1641
|
+
borderRadius: 8,
|
|
1642
|
+
backgroundColor: isAutoRamLimitEnabled
|
|
1643
|
+
? `${AppColors_1.AppColors.purple}14`
|
|
1644
|
+
: AppColors_1.AppColors.grayBackground,
|
|
1645
|
+
alignItems: 'center',
|
|
1646
|
+
justifyContent: 'center',
|
|
1647
|
+
}}>
|
|
1648
|
+
<NetworkIcons_1.SignalIcon color={isAutoRamLimitEnabled
|
|
1649
|
+
? AppColors_1.AppColors.purple
|
|
1650
|
+
: AppColors_1.AppColors.grayTextWeak} size={15}/>
|
|
1651
|
+
</react_native_1.View>
|
|
1652
|
+
<react_native_1.View style={{ flex: 1 }}>
|
|
1653
|
+
<react_native_1.Text style={{
|
|
1654
|
+
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
1655
|
+
fontSize: 13.5,
|
|
1656
|
+
lineHeight: 18,
|
|
1657
|
+
color: isAutoRamLimitEnabled
|
|
1658
|
+
? AppColors_1.AppColors.primaryBlack
|
|
1659
|
+
: AppColors_1.AppColors.grayText,
|
|
1660
|
+
}}>
|
|
1661
|
+
Detected Available RAM
|
|
1662
|
+
</react_native_1.Text>
|
|
1663
|
+
<react_native_1.Text style={{
|
|
1664
|
+
fontFamily: AppFonts_1.AppFonts.interRegular,
|
|
1665
|
+
fontSize: 11,
|
|
1666
|
+
lineHeight: 15,
|
|
1667
|
+
color: AppColors_1.AppColors.grayText,
|
|
1668
|
+
marginTop: 1,
|
|
1669
|
+
}}>
|
|
1670
|
+
{deviceFreeRamMb} MB available on device
|
|
1671
|
+
</react_native_1.Text>
|
|
1672
|
+
</react_native_1.View>
|
|
1673
|
+
<react_native_1.View style={{
|
|
1674
|
+
paddingHorizontal: 10,
|
|
1675
|
+
paddingVertical: 5,
|
|
1676
|
+
borderRadius: 8,
|
|
1677
|
+
backgroundColor: isAutoRamLimitEnabled
|
|
1678
|
+
? `${AppColors_1.AppColors.purple}12`
|
|
1679
|
+
: AppColors_1.AppColors.grayBackground,
|
|
1680
|
+
borderWidth: 1,
|
|
1681
|
+
borderColor: isAutoRamLimitEnabled
|
|
1682
|
+
? `${AppColors_1.AppColors.purple}26`
|
|
1683
|
+
: AppColors_1.AppColors.dividerColor,
|
|
1684
|
+
}}>
|
|
1685
|
+
<react_native_1.Text style={{
|
|
1686
|
+
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
1687
|
+
fontSize: 12,
|
|
1688
|
+
lineHeight: 15,
|
|
1689
|
+
color: isAutoRamLimitEnabled
|
|
1690
|
+
? AppColors_1.AppColors.purple
|
|
1691
|
+
: AppColors_1.AppColors.grayText,
|
|
1692
|
+
}}>
|
|
1693
|
+
{deviceFreeRamMb} MB
|
|
1694
|
+
</react_native_1.Text>
|
|
1695
|
+
</react_native_1.View>
|
|
1696
|
+
</react_native_1.View>
|
|
1697
|
+
|
|
1698
|
+
{/* Profile Overview */}
|
|
1699
|
+
<react_native_1.View style={{
|
|
1700
|
+
marginTop: 4,
|
|
1701
|
+
paddingTop: 8,
|
|
1702
|
+
borderTopWidth: 1,
|
|
1703
|
+
borderTopColor: AppColors_1.AppColors.dividerColor,
|
|
1704
|
+
gap: 6,
|
|
1705
|
+
}}>
|
|
1706
|
+
<react_native_1.View style={{
|
|
1707
|
+
flexDirection: 'row',
|
|
1708
|
+
alignItems: 'center',
|
|
1709
|
+
justifyContent: 'space-between',
|
|
1710
|
+
}}>
|
|
1711
|
+
<react_native_1.Text style={{
|
|
1712
|
+
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
1713
|
+
fontSize: 11.5,
|
|
1714
|
+
lineHeight: 15,
|
|
1715
|
+
color: AppColors_1.AppColors.purple,
|
|
1716
|
+
}}>
|
|
1717
|
+
Profile: {autoRamProfile.profileName}
|
|
1718
|
+
</react_native_1.Text>
|
|
1719
|
+
<react_native_1.View style={{
|
|
1720
|
+
backgroundColor: isAutoRamLimitEnabled
|
|
1721
|
+
? `${AppColors_1.AppColors.emerald500}18`
|
|
1722
|
+
: `${AppColors_1.AppColors.purple}18`,
|
|
1723
|
+
paddingHorizontal: 7,
|
|
1724
|
+
paddingVertical: 2.5,
|
|
1725
|
+
borderRadius: 4,
|
|
1726
|
+
}}>
|
|
1727
|
+
<react_native_1.Text style={{
|
|
1728
|
+
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
1729
|
+
fontSize: 9.5,
|
|
1730
|
+
color: isAutoRamLimitEnabled
|
|
1731
|
+
? AppColors_1.AppColors.emerald500
|
|
1732
|
+
: AppColors_1.AppColors.purple,
|
|
1733
|
+
}}>
|
|
1734
|
+
{isAutoRamLimitEnabled ? 'AUTO-TUNED' : 'MANUAL'}
|
|
1735
|
+
</react_native_1.Text>
|
|
1736
|
+
</react_native_1.View>
|
|
1737
|
+
</react_native_1.View>
|
|
1738
|
+
|
|
1739
|
+
<react_native_1.View style={{ flexDirection: 'row', flexWrap: 'wrap', gap: 8, marginTop: 4 }}>
|
|
1740
|
+
{[
|
|
1741
|
+
{
|
|
1742
|
+
label: 'APIs',
|
|
1743
|
+
value: isAutoRamLimitEnabled
|
|
1744
|
+
? autoRamProfile.maxNetworkLogs
|
|
1745
|
+
: maxNetworkLogs,
|
|
1746
|
+
color: AppColors_1.AppColors.blue500,
|
|
1747
|
+
},
|
|
1748
|
+
{
|
|
1749
|
+
label: 'Logs',
|
|
1750
|
+
value: isAutoRamLimitEnabled
|
|
1751
|
+
? autoRamProfile.maxConsoleLogs
|
|
1752
|
+
: maxConsoleLogs,
|
|
1753
|
+
color: AppColors_1.AppColors.sky500,
|
|
1754
|
+
},
|
|
1755
|
+
{
|
|
1756
|
+
label: 'Analytics',
|
|
1757
|
+
value: isAutoRamLimitEnabled
|
|
1758
|
+
? autoRamProfile.maxAnalyticsEvents
|
|
1759
|
+
: maxAnalyticsEventsLimit,
|
|
1760
|
+
color: AppColors_1.AppColors.purple,
|
|
1761
|
+
},
|
|
1762
|
+
{
|
|
1763
|
+
label: 'Crash',
|
|
1764
|
+
value: isAutoRamLimitEnabled
|
|
1765
|
+
? autoRamProfile.maxCrashRecords
|
|
1766
|
+
: maxCrashLogs,
|
|
1767
|
+
color: AppColors_1.AppColors.errorColor,
|
|
1768
|
+
},
|
|
1769
|
+
].map(item => (<react_native_1.View key={item.label} style={{
|
|
1770
|
+
flexDirection: 'row',
|
|
1771
|
+
alignItems: 'center',
|
|
1772
|
+
gap: 4,
|
|
1773
|
+
paddingHorizontal: 8,
|
|
1774
|
+
paddingVertical: 4,
|
|
1775
|
+
borderRadius: 6,
|
|
1776
|
+
backgroundColor: `${item.color}14`,
|
|
1777
|
+
borderWidth: 1,
|
|
1778
|
+
borderColor: `${item.color}33`,
|
|
1779
|
+
}}>
|
|
1780
|
+
<react_native_1.Text style={{
|
|
1781
|
+
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
1782
|
+
fontSize: 10.5,
|
|
1783
|
+
lineHeight: 14,
|
|
1784
|
+
color: item.color,
|
|
1785
|
+
}}>
|
|
1786
|
+
{item.label}:
|
|
1787
|
+
</react_native_1.Text>
|
|
1788
|
+
<react_native_1.Text style={{
|
|
1789
|
+
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
1790
|
+
fontSize: 10.5,
|
|
1791
|
+
lineHeight: 14,
|
|
1792
|
+
color: item.color,
|
|
1793
|
+
}}>
|
|
1794
|
+
{item.value} max
|
|
1795
|
+
</react_native_1.Text>
|
|
1796
|
+
</react_native_1.View>))}
|
|
1797
|
+
</react_native_1.View>
|
|
1798
|
+
</react_native_1.View>
|
|
1799
|
+
</react_native_1.View>
|
|
1800
|
+
|
|
1801
|
+
{/* Section 2: Memory-Safe OS Pruning Shield */}
|
|
1802
|
+
<react_native_1.View style={{
|
|
1803
|
+
backgroundColor: AppColors_1.AppColors.primaryLight,
|
|
1804
|
+
borderRadius: 14,
|
|
1805
|
+
borderWidth: 1,
|
|
1806
|
+
borderColor: AppColors_1.AppColors.grayBorderSecondary,
|
|
1807
|
+
overflow: 'hidden',
|
|
1808
|
+
padding: 14,
|
|
1809
|
+
gap: 12,
|
|
1810
|
+
}}>
|
|
1811
|
+
<react_native_1.Text style={{
|
|
1812
|
+
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
1813
|
+
fontSize: 11,
|
|
1814
|
+
lineHeight: 14,
|
|
1815
|
+
color: AppColors_1.AppColors.grayTextWeak,
|
|
1816
|
+
letterSpacing: 0.8,
|
|
1817
|
+
}}>
|
|
1818
|
+
LOW MEMORY PRESSURE PROTECTION
|
|
1819
|
+
</react_native_1.Text>
|
|
1820
|
+
|
|
1821
|
+
<react_native_1.View style={{ flexDirection: 'row', alignItems: 'center', gap: 10 }}>
|
|
1822
|
+
<react_native_1.View style={{
|
|
1823
|
+
width: 32,
|
|
1824
|
+
height: 32,
|
|
1825
|
+
borderRadius: 8,
|
|
1826
|
+
backgroundColor: `${AppColors_1.AppColors.emerald500}14`,
|
|
1827
|
+
alignItems: 'center',
|
|
1828
|
+
justifyContent: 'center',
|
|
1829
|
+
}}>
|
|
1830
|
+
<NetworkIcons_1.ShieldAlertIcon color={AppColors_1.AppColors.emerald500} size={15}/>
|
|
1831
|
+
</react_native_1.View>
|
|
1832
|
+
<react_native_1.View style={{ flex: 1 }}>
|
|
1833
|
+
<react_native_1.Text style={{
|
|
1834
|
+
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
1835
|
+
fontSize: 13.5,
|
|
1836
|
+
lineHeight: 18,
|
|
1837
|
+
color: AppColors_1.AppColors.primaryBlack,
|
|
1838
|
+
}}>
|
|
1839
|
+
OS Memory Warning Guard
|
|
1840
|
+
</react_native_1.Text>
|
|
1841
|
+
<react_native_1.Text style={{
|
|
1842
|
+
fontFamily: AppFonts_1.AppFonts.interRegular,
|
|
1843
|
+
fontSize: 11,
|
|
1844
|
+
lineHeight: 15,
|
|
1845
|
+
color: AppColors_1.AppColors.grayText,
|
|
1846
|
+
marginTop: 1,
|
|
1847
|
+
}}>
|
|
1848
|
+
Automatically prunes in-memory buffers by 50% when the OS signals low memory
|
|
1849
|
+
</react_native_1.Text>
|
|
1850
|
+
</react_native_1.View>
|
|
1851
|
+
<react_native_1.View style={{
|
|
1852
|
+
paddingHorizontal: 8,
|
|
1853
|
+
paddingVertical: 3,
|
|
1854
|
+
borderRadius: 6,
|
|
1855
|
+
backgroundColor: `${AppColors_1.AppColors.emerald500}18`,
|
|
1856
|
+
}}>
|
|
1857
|
+
<react_native_1.Text style={{
|
|
1858
|
+
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
1859
|
+
fontSize: 10,
|
|
1860
|
+
color: AppColors_1.AppColors.emerald500,
|
|
1861
|
+
}}>
|
|
1862
|
+
ACTIVE
|
|
1863
|
+
</react_native_1.Text>
|
|
1864
|
+
</react_native_1.View>
|
|
1865
|
+
</react_native_1.View>
|
|
1866
|
+
|
|
1867
|
+
<react_native_1.View style={{ height: 1, backgroundColor: AppColors_1.AppColors.dividerColor }}/>
|
|
1868
|
+
|
|
1869
|
+
{/* Instant Prune Button */}
|
|
1870
|
+
<react_native_1.View style={{
|
|
1871
|
+
flexDirection: 'row',
|
|
1872
|
+
alignItems: 'center',
|
|
1873
|
+
justifyContent: 'space-between',
|
|
1874
|
+
gap: 10,
|
|
1875
|
+
}}>
|
|
1876
|
+
<react_native_1.View style={{ flex: 1 }}>
|
|
1877
|
+
<react_native_1.Text style={{
|
|
1878
|
+
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
1879
|
+
fontSize: 13,
|
|
1880
|
+
color: AppColors_1.AppColors.primaryBlack,
|
|
1881
|
+
}}>
|
|
1882
|
+
Manual Memory Cleanup
|
|
1883
|
+
</react_native_1.Text>
|
|
1884
|
+
<react_native_1.Text style={{
|
|
1885
|
+
fontFamily: AppFonts_1.AppFonts.interRegular,
|
|
1886
|
+
fontSize: 11,
|
|
1887
|
+
color: AppColors_1.AppColors.grayText,
|
|
1888
|
+
marginTop: 1,
|
|
1889
|
+
}}>
|
|
1890
|
+
Prune older entries across all log stores and free RAM
|
|
1891
|
+
</react_native_1.Text>
|
|
1892
|
+
</react_native_1.View>
|
|
1893
|
+
<TouchableScale_1.default onPress={() => {
|
|
1894
|
+
const summary = (0, memoryManager_1.pruneAllLogs)('manual', 0.5);
|
|
1895
|
+
(0, toast_1.showToast)(`Pruned ${summary.totalPruned} items from memory`);
|
|
1896
|
+
}} style={{
|
|
1897
|
+
backgroundColor: AppColors_1.AppColors.purple,
|
|
1898
|
+
paddingHorizontal: 12,
|
|
1899
|
+
paddingVertical: 8,
|
|
1900
|
+
borderRadius: 8,
|
|
1901
|
+
flexDirection: 'row',
|
|
1902
|
+
alignItems: 'center',
|
|
1903
|
+
gap: 5,
|
|
1904
|
+
}}>
|
|
1905
|
+
<NetworkIcons_1.TrashIcon size={13} color={AppColors_1.AppColors.white}/>
|
|
1906
|
+
<react_native_1.Text style={{
|
|
1907
|
+
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
1908
|
+
fontSize: 11.5,
|
|
1909
|
+
color: AppColors_1.AppColors.white,
|
|
1910
|
+
}}>
|
|
1911
|
+
Prune Now
|
|
1912
|
+
</react_native_1.Text>
|
|
1913
|
+
</TouchableScale_1.default>
|
|
1914
|
+
</react_native_1.View>
|
|
1915
|
+
</react_native_1.View>
|
|
1916
|
+
</react_native_1.View>)}
|
|
1706
1917
|
<react_native_1.View style={{ height: 48 }}/>
|
|
1707
1918
|
</react_native_1.ScrollView>
|
|
1708
1919
|
|